--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_13_121101_create_catalog_item_table.php ---
<?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('catalog_item', function (Blueprint $table) {
            $table->id();
            $table->foreignId('catalog_id')->constrained()->onDelete('cascade');
            $table->foreignId('item_id')->constrained()->onDelete('cascade');
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_02_000001_add_status_to_uoms_table.php ---
<?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('uoms', function (Blueprint $table) {
            // Fulfills requirement: store 'active' & 'inactive' status
            // and places it correctly after the price column. [1]
            $table->enum('status', ['active', 'inactive'])->default('active')->after('price');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::table('uoms', function (Blueprint $table) {
            //
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/0001_01_01_000000_create_users_table.php ---
<?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('users', function (Blueprint $table) {
            $table->id();
            $table->string('login_id')->unique(); // Added
            $table->string('name');
            $table->string('email')->unique();
            $table->timestamp('email_verified_at')->nullable();
            $table->string('password');
            $table->enum('status', ['active', 'deactive']);
            $table->foreignId('parent_id')->nullable()->constrained('users')->onDelete('set null');
            $table->unsignedBigInteger('catalog_id')->nullable();

            $table->rememberToken();
            $table->timestamps();
        });

        Schema::create('password_reset_tokens', function (Blueprint $table) {
            $table->string('email')->primary();
            $table->string('token');
            $table->timestamp('created_at')->nullable();
        });

        Schema::create('sessions', function (Blueprint $table) {
            $table->string('id')->primary();
            $table->foreignId('user_id')->nullable()->index();
            $table->string('ip_address', 45)->nullable();
            $table->text('user_agent')->nullable();
            $table->longText('payload');
            $table->integer('last_activity')->index();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_21_000001_add_logistics_to_orders_table.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::table('orders', function (Blueprint $table) {
            $table->string('tracking_number')->nullable()->after('status');
            $table->string('logistics_carrier')->nullable()->after('tracking_number');
        });
    }

    public function down(): void
    {
        Schema::table('orders', function (Blueprint $table) {
            $table->dropColumn(['tracking_number', 'logistics_carrier']);
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/0001_01_01_000001_create_cache_table.php ---
<?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('cache', function (Blueprint $table) {
            $table->string('key')->primary();
            $table->mediumText('value');
            $table->integer('expiration');
        });

        Schema::create('cache_locks', function (Blueprint $table) {
            $table->string('key')->primary();
            $table->string('owner');
            $table->integer('expiration');
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_20_000001_create_orders_table.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::create('orders', function (Blueprint $table) {
            $table->id();
            $table->string('order_number')->nullable()->unique();
            $table->foreignId('user_id')->constrained()->onDelete('cascade');
            $table->foreignId('handler_id')->nullable()->constrained('users')->onDelete('set null');

            // Fulfills Section 4: Lifecycle Statuses
            $table->enum('status', ['draft', 'pending', 'approved', 'in_transit', 'completed', 'cancelled'])->default('draft');

            // Fulfills Section 4.6 & 6: Cancellation and Notes
            $table->text('cancellation_reason')->nullable();
            $table->text('internal_notes')->nullable();
            $table->timestamps();
        });

        Schema::create('order_items', function (Blueprint $table) {
            $table->id();
            $table->foreignId('order_id')->constrained()->onDelete('cascade');
            $table->foreignId('item_id')->constrained()->onDelete('restrict');

            // Fulfills Section 3C: Item Name Snapshot Logic
            // This stores the name at the moment of approval/submission
            $table->string('snapshot_name');

            $table->integer('quantity');
            $table->decimal('price_at_order', 10, 2);
            $table->timestamps();
        });
    }

    public function down(): void
    {
        Schema::dropIfExists('order_items');
        Schema::dropIfExists('orders');
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_02_21_141626_create_order_status_history_table.php ---
<?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('order_status_history', function (Blueprint $table) {
            $table->id();
            $table->foreignId('order_id')->constrained()->onDelete('cascade');
            $table->string('status');
            $table->foreignId('changed_by')->constrained('users')->onDelete('cascade');
            $table->timestamps();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/0001_01_01_000002_create_jobs_table.php ---
<?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('jobs', function (Blueprint $table) {
            $table->id();
            $table->string('queue')->index();
            $table->longText('payload');
            $table->unsignedTinyInteger('attempts');
            $table->unsignedInteger('reserved_at')->nullable();
            $table->unsignedInteger('available_at');
            $table->unsignedInteger('created_at');
        });

        Schema::create('job_batches', function (Blueprint $table) {
            $table->string('id')->primary();
            $table->string('name');
            $table->integer('total_jobs');
            $table->integer('pending_jobs');
            $table->integer('failed_jobs');
            $table->longText('failed_job_ids');
            $table->mediumText('options')->nullable();
            $table->integer('cancelled_at')->nullable();
            $table->integer('created_at');
            $table->integer('finished_at')->nullable();
        });

        Schema::create('failed_jobs', function (Blueprint $table) {
            $table->id();
            $table->string('uuid')->unique();
            $table->text('connection');
            $table->text('queue');
            $table->longText('payload');
            $table->longText('exception');
            $table->timestamp('failed_at')->useCurrent();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_08_034025_add_batch_uuid_column_to_activity_log_table.php ---
<?php

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

class AddBatchUuidColumnToActivityLogTable extends Migration
{
    public function up()
    {
        Schema::connection(config('activitylog.database_connection'))->table(config('activitylog.table_name'), function (Blueprint $table) {
            $table->uuid('batch_uuid')->nullable()->after('properties');
        });
    }

    public function down()
    {
        Schema::connection(config('activitylog.database_connection'))->table(config('activitylog.table_name'), function (Blueprint $table) {
            $table->dropColumn('batch_uuid');
        });
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_13_121102_add_catalog_id_foreign_to_users_table.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::table('users', function (Blueprint $table) {
            // Now that 'catalogs' table exists, we can safely add the constraint
            $table->foreign('catalog_id')
                ->references('id')
                ->on('catalogs')
                ->onDelete('set null');
        });
    }

    public function down(): void
    {
        Schema::table('users', function (Blueprint $table) {
            $table->dropForeign(['catalog_id']);
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_08_034024_add_event_column_to_activity_log_table.php ---
<?php

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

class AddEventColumnToActivityLogTable extends Migration
{
    public function up()
    {
        Schema::connection(config('activitylog.database_connection'))->table(config('activitylog.table_name'), function (Blueprint $table) {
            $table->string('event')->nullable()->after('subject_type');
        });
    }

    public function down()
    {
        Schema::connection(config('activitylog.database_connection'))->table(config('activitylog.table_name'), function (Blueprint $table) {
            $table->dropColumn('event');
        });
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_01_000002_create_uoms_table.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::create('uoms', function (Blueprint $table) {
            $table->id();
            $table->foreignId('item_id')->constrained()->onDelete('cascade');
            $table->string('uom_name'); // e.g., "Carton", "Pack" [Addendum 3.a]
            $table->integer('rate_qty'); // e.g., 24
            $table->decimal('price', 10, 2); // Hidden from customers
            $table->softDeletes(); // For "Hide" rule [Addendum 3.c]
            $table->timestamps();
        });
    }

    public function down(): void
    {
        Schema::dropIfExists('uoms');
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_08_034023_create_activity_log_table.php ---
<?php

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

class CreateActivityLogTable extends Migration
{
    public function up()
    {
        Schema::connection(config('activitylog.database_connection'))->create(config('activitylog.table_name'), function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->string('log_name')->nullable();
            $table->text('description');
            $table->nullableMorphs('subject', 'subject');
            $table->nullableMorphs('causer', 'causer');
            $table->json('properties')->nullable();
            $table->timestamps();
            $table->index('log_name');
        });
    }

    public function down()
    {
        Schema::connection(config('activitylog.database_connection'))->dropIfExists(config('activitylog.table_name'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_05_000001_add_cancellation_request_fields_to_orders_table.php ---
<?php

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

return new class extends Migration
{
    /**
     * Fulfills Addendum Section 2: Enhanced Order Security
     * Adds tracking for the "Request-Response" cancellation protocol.
     */
    public function up(): void
    {
        Schema::table('orders', function (Blueprint $table) {
            // Stores the ID of the CS Staff who initiated the request
            $table->foreignId('cancellation_requested_by')
                ->nullable()
                ->after('internal_notes')
                ->constrained('users')
                ->onDelete('set null');

            // Stores the mandatory reason provided by the staff member
            $table->text('cancellation_request_reason')
                ->nullable()
                ->after('cancellation_requested_by');
        });
    }

    public function down(): void
    {
        Schema::table('orders', function (Blueprint $table) {
            $table->dropForeign(['cancellation_requested_by']);
            $table->dropColumn(['cancellation_requested_by', 'cancellation_request_reason']);
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_06_041707_add_assigned_cs_id_to_users_table.php ---
<?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('users', function (Blueprint $table) {
            // Add a field pointing to the CS Staff's user ID
            $table->foreignId('assigned_cs_id')->nullable()->constrained('users')->onDelete('set null');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::table('users', function (Blueprint $table) {
            //
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_02_01_000001_create_categories_table.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::create('categories', function (Blueprint $table) {
            $table->id();
            $table->string('name')->unique();
            $table->timestamps();
        });

        Schema::create('category_item', function (Blueprint $table) {
            $table->id();
            $table->foreignId('category_id')->constrained()->onDelete('cascade');
            $table->foreignId('item_id')->constrained()->onDelete('cascade');
        });
    }

    public function down(): void
    {
        Schema::dropIfExists('category_item');
        Schema::dropIfExists('categories');
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_01_000001_refactor_user_customer_relationship.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        // 1. Update customer_details to include business codes [Addendum 1.c]
        Schema::table('customer_details', function (Blueprint $table) {
            $table->dropForeign(['user_id']); // Remove old 1:1 link
            $table->dropColumn('user_id');
            $table->string('company_code')->nullable()->unique()->after('id'); // For HQ
            $table->string('branch_code')->nullable()->unique()->after('company_code'); // For Branches
        });

        // 2. Update users to link to a shared Customer Detail record [Addendum 1.a]
        Schema::table('users', function (Blueprint $table) {
            $table->foreignId('customer_detail_id')->nullable()->constrained('customer_details')->onDelete('set null')->after('parent_id');
        });
    }

    public function down(): void
    {
        Schema::table('users', function (Blueprint $table) {
            $table->dropForeign(['customer_detail_id']);
            $table->dropColumn('customer_detail_id');
        });
        Schema::table('customer_details', function (Blueprint $table) {
            $table->foreignId('user_id')->nullable()->constrained()->onDelete('cascade');
            $table->dropColumn(['company_code', 'branch_code']);
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_15_000001_update_order_and_items_table_for_v1_4.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        // 1. Update Order Status Enum
        Schema::table('orders', function (Blueprint $table) {
            $table->string('status')->default('draft')->change();
        });

        // 2. Update Order Items for UOM Snapshots [Addendum 5.a]
        Schema::table('order_items', function (Blueprint $table) {
            $table->foreignId('uom_id')->nullable()->after('item_id')->constrained('uoms')->onDelete('set null');
            $table->string('snapshot_uom_name')->nullable()->after('snapshot_name');
            $table->integer('snapshot_uom_rate')->nullable()->after('snapshot_uom_name');
        });

        // 3. ARCHITECTURE FIX: Drop foreign key before dropping column [Addendum 2.a]
        Schema::table('users', function (Blueprint $table) {
            $table->dropForeign(['parent_id']); // Must drop constraint first
            $table->dropColumn('parent_id');
        });
    }

    public function down(): void
    {
        Schema::table('users', function (Blueprint $table) {
            $table->foreignId('parent_id')->nullable()->constrained('users')->onDelete('set null');
        });

        Schema::table('order_items', function (Blueprint $table) {
            $table->dropForeign(['uom_id']);
            $table->dropColumn(['uom_id', 'snapshot_uom_name', 'snapshot_uom_rate']);
        });
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_03_10_000001_rename_details_to_companys_and_refactor_relationships.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        // 1. Rename the table [Addendum 1.a]
        Schema::rename('customer_details', 'companys');

        Schema::table('companys', function (Blueprint $table) {
            // 2. Move catalog_id from users to companys [Addendum 1.b]
            $table->foreignId('catalog_id')->nullable()->after('id')->constrained('catalogs')->onDelete('set null');

            // 3. Add parent_id to companys to manage business hierarchy directly [Addendum 3.c]
            $table->foreignId('parent_id')->nullable()->after('catalog_id')->constrained('companys')->onDelete('set null');
        });

        // 4. Data Migration: Move existing catalog_id assignments from users to their respective companies
        $usersWithCatalogs = DB::table('users')->whereNotNull('catalog_id')->whereNotNull('customer_detail_id')->get();
        foreach ($usersWithCatalogs as $user) {
            DB::table('companys')->where('id', $user->customer_detail_id)->update(['catalog_id' => $user->catalog_id]);
        }

        // 5. Refactor Users table [Addendum 2.a]
        Schema::table('users', function (Blueprint $table) {
            $table->dropForeign(['catalog_id']);
            $table->dropColumn('catalog_id');
            $table->renameColumn('customer_detail_id', 'company_id');
        });
    }

    public function down(): void
    {
        Schema::table('users', function (Blueprint $table) {
            $table->renameColumn('company_id', 'customer_detail_id');
            $table->unsignedBigInteger('catalog_id')->nullable();
            $table->foreign('catalog_id')->references('id')->on('catalogs')->onDelete('set null');
        });

        Schema::table('companys', function (Blueprint $table) {
            $table->dropForeign(['parent_id']);
            $table->dropColumn(['parent_id', 'catalog_id']);
        });

        Schema::rename('companys', 'customer_details');
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_03_024234_create_permission_tables.php ---
<?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
    {
        $teams = config('permission.teams');
        $tableNames = config('permission.table_names');
        $columnNames = config('permission.column_names');
        $pivotRole = $columnNames['role_pivot_key'] ?? 'role_id';
        $pivotPermission = $columnNames['permission_pivot_key'] ?? 'permission_id';

        throw_if(empty($tableNames), Exception::class, 'Error: config/permission.php not loaded. Run [php artisan config:clear] and try again.');
        throw_if($teams && empty($columnNames['team_foreign_key'] ?? null), Exception::class, 'Error: team_foreign_key on config/permission.php not loaded. Run [php artisan config:clear] and try again.');

        Schema::create($tableNames['permissions'], static function (Blueprint $table) {
            // $table->engine('InnoDB');
            $table->bigIncrements('id'); // permission id
            $table->string('name');       // For MyISAM use string('name', 225); // (or 166 for InnoDB with Redundant/Compact row format)
            $table->string('guard_name'); // For MyISAM use string('guard_name', 25);
            $table->timestamps();

            $table->unique(['name', 'guard_name']);
        });

        Schema::create($tableNames['roles'], static function (Blueprint $table) use ($teams, $columnNames) {
            // $table->engine('InnoDB');
            $table->bigIncrements('id'); // role id
            if ($teams || config('permission.testing')) { // permission.testing is a fix for sqlite testing
                $table->unsignedBigInteger($columnNames['team_foreign_key'])->nullable();
                $table->index($columnNames['team_foreign_key'], 'roles_team_foreign_key_index');
            }
            $table->string('name');       // For MyISAM use string('name', 225); // (or 166 for InnoDB with Redundant/Compact row format)
            $table->string('guard_name'); // For MyISAM use string('guard_name', 25);
            $table->timestamps();
            if ($teams || config('permission.testing')) {
                $table->unique([$columnNames['team_foreign_key'], 'name', 'guard_name']);
            } else {
                $table->unique(['name', 'guard_name']);
            }
        });

        Schema::create($tableNames['model_has_permissions'], static function (Blueprint $table) use ($tableNames, $columnNames, $pivotPermission, $teams) {
            $table->unsignedBigInteger($pivotPermission);

            $table->string('model_type');
            $table->unsignedBigInteger($columnNames['model_morph_key']);
            $table->index([$columnNames['model_morph_key'], 'model_type'], 'model_has_permissions_model_id_model_type_index');

            $table->foreign($pivotPermission)
                ->references('id') // permission id
                ->on($tableNames['permissions'])
                ->onDelete('cascade');
            if ($teams) {
                $table->unsignedBigInteger($columnNames['team_foreign_key']);
                $table->index($columnNames['team_foreign_key'], 'model_has_permissions_team_foreign_key_index');

                $table->primary([$columnNames['team_foreign_key'], $pivotPermission, $columnNames['model_morph_key'], 'model_type'],
                    'model_has_permissions_permission_model_type_primary');
            } else {
                $table->primary([$pivotPermission, $columnNames['model_morph_key'], 'model_type'],
                    'model_has_permissions_permission_model_type_primary');
            }

        });

        Schema::create($tableNames['model_has_roles'], static function (Blueprint $table) use ($tableNames, $columnNames, $pivotRole, $teams) {
            $table->unsignedBigInteger($pivotRole);

            $table->string('model_type');
            $table->unsignedBigInteger($columnNames['model_morph_key']);
            $table->index([$columnNames['model_morph_key'], 'model_type'], 'model_has_roles_model_id_model_type_index');

            $table->foreign($pivotRole)
                ->references('id') // role id
                ->on($tableNames['roles'])
                ->onDelete('cascade');
            if ($teams) {
                $table->unsignedBigInteger($columnNames['team_foreign_key']);
                $table->index($columnNames['team_foreign_key'], 'model_has_roles_team_foreign_key_index');

                $table->primary([$columnNames['team_foreign_key'], $pivotRole, $columnNames['model_morph_key'], 'model_type'],
                    'model_has_roles_role_model_type_primary');
            } else {
                $table->primary([$pivotRole, $columnNames['model_morph_key'], 'model_type'],
                    'model_has_roles_role_model_type_primary');
            }
        });

        Schema::create($tableNames['role_has_permissions'], static function (Blueprint $table) use ($tableNames, $pivotRole, $pivotPermission) {
            $table->unsignedBigInteger($pivotPermission);
            $table->unsignedBigInteger($pivotRole);

            $table->foreign($pivotPermission)
                ->references('id') // permission id
                ->on($tableNames['permissions'])
                ->onDelete('cascade');

            $table->foreign($pivotRole)
                ->references('id') // role id
                ->on($tableNames['roles'])
                ->onDelete('cascade');

            $table->primary([$pivotPermission, $pivotRole], 'role_has_permissions_permission_id_role_id_primary');
        });

        app('cache')
            ->store(config('permission.cache.store') != 'default' ? config('permission.cache.store') : null)
            ->forget(config('permission.cache.key'));
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        $tableNames = config('permission.table_names');

        throw_if(empty($tableNames), Exception::class, 'Error: config/permission.php not found and defaults could not be merged. Please publish the package configuration before proceeding, or drop the tables manually.');

        Schema::drop($tableNames['role_has_permissions']);
        Schema::drop($tableNames['model_has_roles']);
        Schema::drop($tableNames['model_has_permissions']);
        Schema::drop($tableNames['roles']);
        Schema::drop($tableNames['permissions']);
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_13_121020_create_catalogs_table.php ---
<?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('catalogs', function (Blueprint $table) {
            $table->id();
            $table->string('name'); // e.g., "General", "East Malaysia", "VIP"
            $table->timestamps();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_06_033051_create_customer_details_table.php ---
<?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('customer_details', function (Blueprint $table) {
            $table->id();
            $table->foreignId('user_id')->constrained()->onDelete('cascade');

            // Business Information
            $table->string('company_name')->nullable();
            $table->string('company_reg_no')->nullable(); // For SSM No

            // Person In Charge (PIC) Details
            $table->string('pic_name')->nullable();
            $table->string('pic_phone')->nullable();

            // Logistics Information
            $table->text('delivery_address')->nullable();
            $table->string('postal_code')->nullable();
            $table->string('city')->nullable();
            $table->string('state')->nullable();

            $table->timestamps();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_01_13_121039_create_items_table.php ---
<?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('items', function (Blueprint $table) {
            $table->id();
            $table->string('sku')->unique();
            $table->string('name');
            $table->text('description')->nullable();
            $table->string('image_path')->nullable(); // For automated compression later [3]
            $table->timestamps();
        });
    }

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

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/migrations/2026_02_10_000001_add_status_to_product_entities.php ---
<?php

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

return new class extends Migration
{
    public function up(): void
    {
        Schema::table('items', function (Blueprint $table) {
            // ARCHITECTURE FIX: Changed anchor from 'price' to 'description'
            // to resolve SQLSTATE[42S22] Column not found error.
            $table->enum('status', ['active', 'deactive'])->default('active')->after('description');
        });

        Schema::table('catalogs', function (Blueprint $table) {
            $table->enum('status', ['active', 'deactive'])->default('active')->after('name');
        });

        Schema::table('categories', function (Blueprint $table) {
            $table->enum('status', ['active', 'deactive'])->default('active')->after('name');
        });
    }

    public function down(): void
    {
        Schema::table('items', fn ($table) => $table->dropColumn('status'));
        Schema::table('catalogs', fn ($table) => $table->dropColumn('status'));
        Schema::table('categories', fn ($table) => $table->dropColumn('status'));
    }
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/seeders/RoleSeeder.php ---
<?php

namespace Database\Seeders;

use Illuminate\Database\Seeder;
use Spatie\Permission\Models\Permission;
use Spatie\Permission\Models\Role;

class RoleSeeder extends Seeder
{
    public function run(): void
    {
        // 1. Reset cached roles and permissions
        app()[\Spatie\Permission\PermissionRegistrar::class]->forgetCachedPermissions();

        // 2. Create Permissions
        // We use firstOrCreate to prevent errors if you run seed multiple times
        Permission::firstOrCreate(['name' => 'view_business_entities']);
        Permission::firstOrCreate(['name' => 'view_login_credentials']);
        Permission::firstOrCreate(['name' => 'create_users']);
        Permission::firstOrCreate(['name' => 'edit_users']);
        Permission::firstOrCreate(['name' => 'view_assigned_customers']);
        Permission::firstOrCreate(['name' => 'edit_assigned_customers']);
        Permission::firstOrCreate(['name' => 'reassign_customers']);
        Permission::firstOrCreate(['name' => 'view_catalogs']);
        Permission::firstOrCreate(['name' => 'create_catalogs']);
        Permission::firstOrCreate(['name' => 'edit_catalogs']);
        Permission::firstOrCreate(['name' => 'view_items']);
        Permission::firstOrCreate(['name' => 'create_items']);
        Permission::firstOrCreate(['name' => 'edit_items']);

        // 3. Create Roles
        $admin = Role::firstOrCreate(['name' => 'admin']);
        $admin->syncPermissions(Permission::all());
        $leader = Role::firstOrCreate(['name' => 'cs_leader']);
        $staff = Role::firstOrCreate(['name' => 'cs_staff']);
        $customer = Role::firstOrCreate(['name' => 'customer']);

        // CS LEADER: Can view the list (but maybe not create/edit by default)
        // You can change this later in your "Feature Settings" page.
        $leader->syncPermissions([
            'view_business_entities',
            'view_login_credentials',
            'edit_users',
            'view_assigned_customers',
            'edit_assigned_customers',
            'reassign_customers',
            'view_catalogs',
            'create_catalogs',
            'edit_catalogs',
            'view_items',
            'create_items',
            'edit_items',
        ]);

        // CS STAFF: Starts with nothing (or add 'view_users' if you prefer)
        // $staff->syncPermissions(['view_users']);
        $staff->syncPermissions([
            'view_business_entities',
            'view_login_credentials',
            'view_assigned_customers',
            'edit_assigned_customers',
            'view_catalogs',
            'create_catalogs',
            'edit_catalogs',
            'view_items',
            'create_items',
            'edit_items',
        ]);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/seeders/DatabaseSeeder.php ---
<?php

namespace Database\Seeders;

use App\Models\Catalog;
use App\Models\Company;
use App\Models\Item;
use App\Models\Uom; // Added for strict UOM generation
use App\Models\User; // NEW
use Illuminate\Database\Seeder;

class DatabaseSeeder extends Seeder
{
    public function run(): void
    {
        $this->call(RoleSeeder::class);

        // 1. Create Items with Mandatory UOMs [Addendum 5.a]
        $items = Item::factory()->count(60)->create()->each(function ($item) {
            // Fulfills Requirement: Random 1 to 5 UOMs
            $uomCount = rand(1, 5);
            $units = ['Box', 'Carton', 'Pack', 'Bundle', 'Pallet'];

            // 1. Mandatory Base Unit (Rate Qty 1) - Already correct in your code [3]
            Uom::create([
                'item_id' => $item->id,
                'uom_name' => 'Individual Unit',
                'rate_qty' => 1,
                'price' => rand(10, 100),
                'status' => 'active',
            ]);

            // 2. ARCHITECTURE FIX: Randomized Secondary Packaging Units [1]
            // Added 'price' field to satisfy NOT NULL constraint for Pure UOM model.
            for ($i = 1; $i < $uomCount; $i++) {
                Uom::create([
                    'item_id' => $item->id,
                    'uom_name' => $units[rand(0, 4)].' '.rand(10, 50).'s',
                    'rate_qty' => rand(5, 100),
                    'price' => rand(150, 1000), // FIXED: Mandatory price field
                    'status' => 'active',
                ]);
            }
        });

        // 2. Create Catalogs and attach items
        $catalogs = Catalog::factory()->count(3)->create()->each(function ($catalog) use ($items) {
            $catalog->items()->attach($items->random(rand(15, 30))->pluck('id')->toArray());
        });

        // 3. Create Internal Staff [Backbone 2.c]
        $admin = User::factory()->create(['name' => 'System Admin', 'login_id' => 'admin001', 'email' => 'admin@maxtop.com', 'status' => 'active']);
        $admin->assignRole('admin');

        $leader = User::factory()->create([
            'name' => 'CS Leader User',
            'email' => 'leader@test.com',
            'login_id' => 'csleader001',
            'status' => 'active',
        ]);
        $leader->assignRole('cs_leader');

        $staff = User::factory()->create(['name' => 'CS Staff User', 'login_id' => 'csstaff001', 'email' => 'staff@test.com', 'status' => 'active']);
        $staff->assignRole('cs_staff');

        // 4. Create Business Hierarchy [Addendum 1.a, 2.a]
        $hqCompany = Company::create([
            'company_code' => 'MAX-HQ-001',
            'company_name' => 'Maxtop HQ Group',
            'catalog_id' => $catalogs->first()->id,
            'delivery_address' => '123 Industrial Park, KL',
        ]);

        $hqUser = User::factory()->create([
            'name' => 'Main HQ Admin',
            'login_id' => 'customer001',
            'company_id' => $hqCompany->id, // Linked to Company entity
            'assigned_cs_id' => $staff->id,
            'status' => 'active',
        ]);
        $hqUser->assignRole('customer');

        // 4. Create Branch Companies and Users [Addendum 3.c]
        for ($i = 1; $i <= 4; $i++) {
            $branchCompany = Company::create([
                'parent_id' => $hqCompany->id, // Business hierarchy
                'branch_code' => "BR-00{$i}",
                'company_name' => "Maxtop Branch {$i}",
                'catalog_id' => null, // Forces inheritance from HQ Catalog [Backbone 3.a.2]
                'delivery_address' => "Branch {$i} Location Address",
            ]);

            $branchUser = User::factory()->create([
                'name' => "Branch User {$i}",
                'login_id' => "branch00{$i}",
                'company_id' => $branchCompany->id,
                'assigned_cs_id' => $staff->id,
                'status' => 'active',
            ]);
            $branchUser->assignRole('customer');
        }
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/factories/CategoryFactory.php ---
<?php

namespace Database\Factories;

use App\Models\Category;
use Illuminate\Database\Eloquent\Factories\Factory;

class CategoryFactory extends Factory
{
    protected $model = Category::class;

    public function definition(): array
    {
        return [
            'name' => $this->faker->unique()->word().' Group',
            'status' => 'active',
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/factories/ItemFactory.php ---
<?php

namespace Database\Factories;

use App\Models\Item;
use Illuminate\Database\Eloquent\Factories\Factory;

class ItemFactory extends Factory
{
    protected $model = Item::class;

    public function definition(): array
    {
        return [
            'sku' => 'MT-'.$this->faker->unique()->numberBetween(1000, 9999),
            'name' => $this->faker->words(3, true),
            'description' => $this->faker->sentence(),
            'status' => 'active', // Defaulting to active for visibility [3]
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/factories/CatalogFactory.php ---
<?php

namespace Database\Factories;

use App\Models\Catalog;
use Illuminate\Database\Eloquent\Factories\Factory;

class CatalogFactory extends Factory
{
    protected $model = Catalog::class;

    public function definition(): array
    {
        return [
            'name' => $this->faker->city().' Region Catalog',
            'status' => 'active',
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/database/factories/UserFactory.php ---
<?php

namespace Database\Factories;

use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Str;

/**
 * @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\User>
 */
class UserFactory extends Factory
{
    /**
     * The current password being used by the factory.
     */
    protected static ?string $password;

    /**
     * Define the model's default state.
     *
     * @return array<string, mixed>
     */
    public function definition(): array
    {
        return [
            'name' => fake()->name(),
            'login_id' => fake()->unique()->userName(),
            'email' => fake()->unique()->safeEmail(),
            'email_verified_at' => now(),
            'password' => static::$password ??= Hash::make('password'),
            'remember_token' => Str::random(10),
        ];
    }

    /**
     * Indicate that the model's email address should be unverified.
     */
    public function unverified(): static
    {
        return $this->state(fn (array $attributes) => [
            'email_verified_at' => null,
        ]);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/tailwind.config.js ---
import defaultTheme from 'tailwindcss/defaultTheme';
import forms from '@tailwindcss/forms';

/** @type {import('tailwindcss').Config} */
export default {
    content: [
        './vendor/laravel/framework/src/Illuminate/Pagination/resources/views/*.blade.php',
        './storage/framework/views/*.php',
        './resources/views/**/*.blade.php',
    ],

    theme: {
        extend: {
            fontFamily: {
                sans: ['Figtree', ...defaultTheme.fontFamily.sans],
            },
        },
    },

    plugins: [forms],
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Traits/Searchable.php ---
<?php

namespace App\Traits;

use Illuminate\Database\Eloquent\Builder;

trait Searchable
{
    public function scopeSearch(Builder $query, ?string $term = null)
    {
        // If no search term, do nothing
        if (! $term) {
            return $query;
        }

        // Search across the columns defined in the model
        $query->where(function ($q) use ($term) {
            foreach ($this->searchable as $field) {
                $q->orWhere($field, 'like', "%{$term}%");
            }
        });

        return $query;
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Traits/DateFilterable.php ---
<?php

namespace App\Traits;

use Illuminate\Database\Eloquent\Builder;

trait DateFilterable
{
    /**
     * Filter query by a date range.
     *
     * @param  string  $column  (Default: created_at)
     * @return Builder
     */
    public function scopeFilterByDate(Builder $query, $column = 'created_at')
    {
        // 1. Check for Start Date
        if (request()->filled('start_date')) {
            $query->whereDate($column, '>=', request('start_date'));
        }

        // 2. Check for End Date
        if (request()->filled('end_date')) {
            $query->whereDate($column, '<=', request('end_date'));
        }

        return $query;
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Traits/RoleFilterable.php ---
<?php

namespace App\Traits;

use Illuminate\Database\Eloquent\Builder;

trait RoleFilterable
{
    /**
     * Filter query by Spatie Role name.
     */
    public function scopeFilterByRole(Builder $query)
    {
        // Check if 'role' is in the URL (e.g. ?role=admin)
        if (request()->filled('role')) {

            // Query the relationship
            return $query->whereHas('roles', function ($q) {
                $q->where('name', request('role'));
            });
        }

        return $query;
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Providers/AppServiceProvider.php ---
<?php

namespace App\Providers;

use Illuminate\Support\ServiceProvider;

class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     */
    public function register(): void
    {
        //
    }

    /**
     * Bootstrap any application services.
     */
    public function boot(): void
    {
        //
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Category.php ---
<?php

namespace App\Models;

use App\Traits\Searchable;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;

class Category extends Model
{
    use HasFactory, LogsActivity,Searchable;

    protected $fillable = ['name', 'status'];

    protected $searchable = ['name', 'status'];

    public function items()
    {
        return $this->belongsToMany(Item::class);
    }

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()->logFillable()->logOnlyDirty();
    }

    /**
     * Fulfills Section 3.c Deletion Restriction:
     * A category can only be hard deleted if none of the items
     * currently assigned to it have transaction history.
     */
    public function canBeDeleted(): bool
    {
        // Check if any items in this category exist in the order_items table
        return ! $this->items()->whereHas('orderItems')->exists();
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Uom.php ---
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Support\Facades\DB;

class Uom extends Model
{
    use SoftDeletes;

    protected $fillable = ['item_id', 'uom_name', 'rate_qty', 'price', 'status'];

    /**
     * ARCHITECTURE FIX: Align visibility guard with Addendum 3.b [4]
     */
    protected function staffPrice(): \Illuminate\Database\Eloquent\Casts\Attribute
    {
        return \Illuminate\Database\Eloquent\Casts\Attribute::make(
            get: function ($value) {
                if (auth()->check() && auth()->user()->hasRole('customer')) {
                    return null;
                }

                return $value;
            }
        );
    }

    /**
     * Fulfills Addendum 5.c: Deletion Rule [5].
     * Prevents hard delete if the UOM is referenced in order history.
     *
     * BUG FIX: Column name corrected from 'snapshot_uom_id' to 'uom_id'
     * to match migration 2026_03_15_000001 [2].
     */
    public function canBeDeleted(): bool
    {
        return ! DB::table('order_items')
            ->where('uom_id', $this->id)
            ->exists();
    }

    /**
     * Scope for customer-facing visibility.
     */
    public function scopeActive($query)
    {
        return $query->where('status', 'active');
    }

    public function item(): BelongsTo
    {
        return $this->belongsTo(Item::class);
    }

    /**
     * ARCHITECTURE FIX: Snapshot Integrity Link [Backbone 5.c.1].
     * Resolves BadMethodCallException by defining the relationship to historical orders.
     */
    public function orderItems(): HasMany
    {
        return $this->hasMany(OrderItem::class);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Catalog.php ---
<?php

namespace App\Models;

use App\Traits\Searchable;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;

class Catalog extends Model
{
    use HasFactory, LogsActivity, Searchable;

    protected $fillable = ['name', 'status'];

    protected $searchable = ['name', 'status'];

    public function items()
    {
        return $this->belongsToMany(Item::class);
    }

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()->logFillable()->logOnlyDirty();
    }

    /**
     * Fulfills Backbone 3.a.1 & Addendum 1.b:
     * Prevents deletion if any Company (HQ or Branch) is assigned to this catalog.
     */
    public function canBeDeleted(): bool
    {
        // ARCHITECTURE FIX: Check assignments in 'companys' table, not 'users' [Addendum 1.b]
        return ! (\App\Models\Company::where('catalog_id', $this->id)->exists());
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Order.php ---
<?php

namespace App\Models;

use App\Traits\Searchable;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;

class Order extends Model
{
    use LogsActivity,Searchable;

    protected $fillable = [
        'order_number',
        'user_id',
        'handler_id',
        'status',
        'cancellation_reason',
        'internal_notes',
        'cancellation_requested_by',
        'cancellation_request_reason',
    ];

    protected $searchable = [
        'order_number', 'status',
    ];

    /**
     * Relationship: The Customer who owns the order/draft.
     */
    public function user(): BelongsTo
    {
        return $this->belongsTo(User::class);
    }

    /**
     * Relationship: The CS Staff currently handling the order.
     * Fulfills Section 5: Ownership logic [6].
     */
    public function handler(): BelongsTo
    {
        return $this->belongsTo(User::class, 'handler_id');
    }

    /**
     * Relationship: The items contained within this order.
     */
    public function items(): HasMany
    {
        return $this->hasMany(OrderItem::class);
    }

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()
            ->logFillable()
            ->logOnlyDirty()
            ->setDescriptionForEvent(fn (string $eventName) => "Order has been {$eventName}");
    }

    public function canBeCancelledDirectly(): bool
    {
        // Approved orders require a request if the user is CS Staff [Addendum 2.a]
        if ($this->status === 'approved' && auth()->user()->hasRole('cs_staff')) {
            return false;
        }

        return true;
    }

    /**
     * ARCHITECTURE FIX: Align helper with Controller status updates.
     * Fulfills Addendum Section 4.b workflow.
     */
    public function hasPendingCancellationRequest(): bool
    {
        // Status is changed to 'cancellation_requested' by the controller during the request phase
        return $this->status === 'cancellation_requested' && ! is_null($this->cancellation_requested_by);
    }

    /**
     * Get the user who requested the cancellation.
     */
    public function cancellationRequester(): \Illuminate\Database\Eloquent\Relations\BelongsTo
    {
        return $this->belongsTo(User::class, 'cancellation_requested_by');
    }

    /**
     * Fulfills Section 5: Assignment & Handover Logic
     * Scopes the query to orders relevant to a specific staff member.
     */
    public function scopeAssignedTo($query, $user)
    {
        return $query->where(function ($q) use ($user) {
            $q->where('handler_id', $user->id)
                ->orWhere(function ($sub) use ($user) {
                    $sub->whereNull('handler_id')
                        ->whereHas('user', function ($u) use ($user) {
                            $u->where('assigned_cs_id', $user->id);
                        });
                });
        });
    }

    /**
     * ARCHITECTURE FIX: Automated Internal Audit Trail.
     * Records every status change and the acting user into order_status_history.
     */
    protected static function booted()
    {
        static::updated(function ($order) {
            if ($order->isDirty('status') && auth()->check()) {
                \Illuminate\Support\Facades\DB::table('order_status_history')->insert([
                    'order_id' => $order->id,
                    'status' => $order->status,
                    'changed_by' => auth()->id(),
                    'created_at' => now(),
                    'updated_at' => now(),
                ]);
            }
        });
    }

    /**
     * ARCHITECTURE FIX: Automated Internal Audit Trail.
     * Records every status change and the acting user into order_status_history.
     */
    public function statusHistory(): \Illuminate\Database\Eloquent\Relations\HasMany
    {
        // This will now resolve correctly because the Model file exists.
        return $this->hasMany(OrderStatusHistory::class)->latest();
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/OrderItem.php ---
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;

class OrderItem extends Model
{
    protected $fillable = [
        'order_id',
        'item_id',
        'uom_id', // ARCHITECTURE FIX: Ensure UOM ID is fillable for grouping
        'snapshot_name',
        'snapshot_uom_name', // Fulfills Audit Snapshot requirement [10.b]
        'snapshot_uom_rate',
        'quantity',
        'price_at_order',
    ];

    public function order(): BelongsTo
    {
        return $this->belongsTo(Order::class);
    }

    public function item(): BelongsTo
    {
        return $this->belongsTo(Item::class);
    }

    /**
     * ARCHITECTURE FIX: Defined missing relationship to resolve "UNIT" display bug.
     */
    public function uom(): BelongsTo
    {
        return $this->belongsTo(Uom::class)->withTrashed(); // Include trashed for historical consistency
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/User.php ---
<?php

namespace App\Models;

use App\Traits\DateFilterable;
use App\Traits\RoleFilterable;
use App\Traits\Searchable;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;
use Spatie\Permission\Traits\HasRoles;

class User extends Authenticatable
{
    use DateFilterable, HasFactory, HasRoles, LogsActivity, Notifiable, RoleFilterable, Searchable;

    protected $fillable = ['name', 'login_id', 'email', 'password', 'status', 'company_id', 'assigned_cs_id'];

    protected $searchable = ['name', 'login_id', 'email', 'status'];

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()->logFillable()->logOnlyDirty();
    }

    /**
     * ARCHITECTURE FIX: Relationship to retrieve the assigned CS Staff member.
     * Fulfills Backbone Section 5.a (Specific Handling) [4].
     */
    public function csRepresentative(): \Illuminate\Database\Eloquent\Relations\BelongsTo
    {
        return $this->belongsTo(User::class, 'assigned_cs_id');
    }

    /**
     * Many Users -> One Company [5, 6]
     */
    public function company(): \Illuminate\Database\Eloquent\Relations\BelongsTo
    {
        return $this->belongsTo(Company::class, 'company_id');
    }

    /**
     * Relationship: Historical and active orders/drafts.
     */
    public function orders(): \Illuminate\Database\Eloquent\Relations\HasMany
    {
        return $this->hasMany(Order::class);
    }

    /**
     * Fulfills Backbone 4.b: Pending Review check.
     * Prevents adding new items to a draft if an order is currently awaiting CS review.
     */
    public function hasPendingOrder(): bool
    {
        return $this->orders()->where('status', 'pending')->exists();
    }

    /**
     * Fulfills Backbone 4.a: Single Draft Policy.
     * Retrieves the current active draft for this user.
     */
    public function currentDraft(): ?Order
    {
        return $this->orders()->where('status', 'draft')->first();
    }

    /**
     * Fulfills ReservationController@store requirement.
     * Returns the existing draft or initializes a new one.
     */
    public function getOrCreateDraft(): Order
    {
        return $this->orders()->firstOrCreate(
            ['status' => 'draft'],
            ['order_number' => null]
        );
    }

    /**
     * Whitelist Logic: Traverses Company -> Parent Company
     */
    public function getEffectiveCatalogId()
    {
        if (! $this->company) {
            return null;
        }

        return $this->company->catalog_id ?? $this->company->parent?->catalog_id;
    }

    /**
     * Retrieve items based on the Single Catalog Policy whitelist.
     */
    public function getVisibleItems(): \Illuminate\Support\Collection
    {
        $catalogId = $this->getEffectiveCatalogId();

        return $catalogId
            ? Item::whereHas('catalogs', fn ($q) => $q->where('catalogs.id', $catalogId))->get()
            : collect();
    }

    /**
     * Fulfills Section 3.c Deletion Restriction.
     */
    public function canBeDeleted(): bool
    {
        return ! $this->orders()->exists();
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/OrderStatusHistory.php ---
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;

class OrderStatusHistory extends Model
{
    /**
     * ARCHITECTURE FIX: Established Model to resolve ClassNotFoundException.
     * Maps to order_status_history table [Migration v1.4].
     */
    protected $table = 'order_status_history';

    protected $fillable = [
        'order_id',
        'status',
        'changed_by',
    ];

    /**
     * Relationship: The internal user (Admin/CS) who triggered the status change.
     */
    public function changer(): BelongsTo
    {
        return $this->belongsTo(User::class, 'changed_by');
    }

    /**
     * Relationship: The order this history record belongs to.
     */
    public function order(): BelongsTo
    {
        return $this->belongsTo(Order::class);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Company.php ---
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;

class Company extends Model
{
    use LogsActivity;

    protected $table = 'companys'; // Aligning with requested naming

    protected $fillable = [
        'company_code', // HQ Code [1.d]
        'branch_code',  // Branch Code [1.d]
        'parent_id',    // Links Branch to HQ [3.c]
        'catalog_id',   // Whitelist control [1.b]
        'company_name',
        'company_reg_no',
        'pic_name',
        'pic_phone',
        'delivery_address',
        'postal_code',
        'city',
        'state',
    ];

    public function catalog()
    {
        return $this->belongsTo(Catalog::class);
    }

    public function users()
    {
        return $this->hasMany(User::class, 'company_id');
    }

    public function parent()
    {
        return $this->belongsTo(Company::class, 'parent_id');
    }

    public function branches()
    {
        return $this->hasMany(Company::class, 'parent_id');
    }

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()->logFillable()->logOnlyDirty();
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Models/Item.php ---
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Spatie\Activitylog\LogOptions;
use Spatie\Activitylog\Traits\LogsActivity;

class Item extends Model
{
    use HasFactory, LogsActivity;

    protected $fillable = ['sku', 'name', 'description', 'image_path', 'status'];

    public function catalogs()
    {
        return $this->belongsToMany(Catalog::class);
    }

    public function orderItems()
    {
        return $this->hasMany(\App\Models\OrderItem::class);
    }

    /**
     * Fulfills Section 3C: Deletion & Draft Protection
     * Items with ANY transaction record (including Drafts and Pending) cannot be deleted. [1]
     */
    public function canBeDeleted(): bool
    {
        // Fulfills Section 3.c.1 & 3.c.2: Lock if in ANY order status
        return ! $this->orderItems()->exists();
    }

    public function getActivitylogOptions(): LogOptions
    {
        return LogOptions::defaults()->logFillable()->logOnlyDirty();
    }

    // Inside Item class
    public function categories()
    {
        return $this->belongsToMany(Category::class);
    }

    /**
     * Fulfills Section 3.c.2: Check if item is in any active draft.
     */
    public function isInDraft(): bool
    {
        return $this->orderItems()->whereHas('order', function ($query) {
            $query->where('status', 'draft');
        })->exists();
    }

    // ... inside Item class
    public function uoms(): \Illuminate\Database\Eloquent\Relations\HasMany
    {
        // Retrieve all, including hidden (soft-deleted) ones for admin
        return $this->hasMany(Uom::class);
    }

    /**
     * Fulfills Customer Visibility Requirement:
     * Only show choices if the UOM status is 'active'. [2, 3]
     */
    public function activeUoms(): \Illuminate\Database\Eloquent\Relations\HasMany
    {
        // ARCHITECTURE FIX: Switched from SoftDelete-based to Status-based visibility
        return $this->hasMany(Uom::class)->where('status', 'active');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Requests/Auth/LoginRequest.php ---
<?php

namespace App\Http\Requests\Auth;

use Illuminate\Auth\Events\Lockout;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\RateLimiter;
use Illuminate\Support\Str;
use Illuminate\Validation\ValidationException;

class LoginRequest extends FormRequest
{
    /**
     * Determine if the user is authorized to make this request.
     */
    public function authorize(): bool
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array<string, \Illuminate\Contracts\Validation\ValidationRule|array<mixed>|string>
     */
    public function rules(): array
    {
        return [
            'login_id' => ['required', 'string'],
            'password' => ['required', 'string'],
        ];
    }

    /**
     * Attempt to authenticate the request's credentials.
     *
     * @throws \Illuminate\Validation\ValidationException
     */
    public function authenticate(): void
    {
        $this->ensureIsNotRateLimited();

        if (! Auth::attempt($this->only('login_id', 'password'), $this->boolean('remember'))) {
            RateLimiter::hit($this->throttleKey());

            throw ValidationException::withMessages([
                'login_id' => trans('auth.failed'),
            ]);
        }

        RateLimiter::clear($this->throttleKey());
    }

    /**
     * Ensure the login request is not rate limited.
     *
     * @throws \Illuminate\Validation\ValidationException
     */
    public function ensureIsNotRateLimited(): void
    {
        if (! RateLimiter::tooManyAttempts($this->throttleKey(), 5)) {
            return;
        }

        event(new Lockout($this));

        $seconds = RateLimiter::availableIn($this->throttleKey());

        throw ValidationException::withMessages([
            'email' => trans('auth.throttle', [
                'seconds' => $seconds,
                'minutes' => ceil($seconds / 60),
            ]),
        ]);
    }

    /**
     * Get the rate limiting throttle key for the request.
     */
    public function throttleKey(): string
    {
        return Str::transliterate(Str::lower($this->string('login_id')).'|'.$this->ip());
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Requests/CS/CancelOrderRequest.php ---
<?php

namespace App\Http\Requests\CS;

use Illuminate\Foundation\Http\FormRequest;

class CancelOrderRequest extends FormRequest
{
    public function authorize(): bool
    {
        // Fulfills Section 5: Only handler or elevated roles can initiate/approve cancellation
        $order = $this->route('order');

        return $order && ($order->handler_id === auth()->id() || auth()->user()->hasAnyRole(['admin', 'cs_leader']));
    }

    /**
     * ARCHITECTURE FIX: Contextual validation for Cancellation.
     * If the order is already in 'cancellation_requested' status, the reason
     * is optional as we fall back to the requester's note.
     */
    public function rules(): array
    {
        $order = $this->route('order');
        $isFinalizing = $order && $order->status === 'cancellation_requested';

        return [
            'cancellation_reason' => $isFinalizing
                ? 'nullable|string|max:1000'
                : 'required|string|min:5|max:1000',
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Requests/ProfileUpdateRequest.php ---
<?php

namespace App\Http\Requests;

use App\Models\User;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Validation\Rule;

class ProfileUpdateRequest extends FormRequest
{
    /**
     * Get the validation rules that apply to the request.
     *
     * @return array<string, \Illuminate\Contracts\Validation\ValidationRule|array<mixed>|string>
     */
    public function rules(): array
    {
        return [
            'name' => ['required', 'string', 'max:255'],
            'email' => [
                'required',
                'string',
                'lowercase',
                'email',
                'max:255',
                Rule::unique(User::class)->ignore($this->user()->id),
            ],
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Requests/Customer/AddToCartRequest.php ---
<?php

namespace App\Http\Requests\Customer;

use Illuminate\Foundation\Http\FormRequest;

class AddToCartRequest extends FormRequest
{
    public function authorize(): bool
    {
        return auth()->user()->hasRole('customer');
    }

    public function rules(): array
    {
        return [
            'item_id' => ['required', 'exists:items,id'],
            // ARCHITECTURE FIX: Mandatory UOM ID requirement [Addendum 5.a]
            'uom_id' => ['required', 'exists:uoms,id'],
            'quantity' => 'required|integer|min:1|max:999',
        ];
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/ActivityLogController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\User;
use Illuminate\Http\Request;
use Spatie\Activitylog\Models\Activity;
use Spatie\Permission\Models\Role;

class ActivityLogController extends Controller
{
    public function index(Request $request)
    {
        $query = Activity::with(['causer', 'subject']);

        // 1. Filter by Date Range (using logic from your DateFilterable trait [1])
        if ($request->filled('start_date')) {
            $query->whereDate('created_at', '>=', $request->start_date);
        }
        if ($request->filled('end_date')) {
            $query->whereDate('created_at', '<=', $request->end_date);
        }

        // 2. Filter by Action Type (description column [2])
        if ($request->filled('action_type')) {
            $query->where('description', $request->action_type);
        }

        // 3. Dynamic Search: Name or Login ID (filtered through the 'causer' relationship)
        if ($request->filled('search')) {
            $term = $request->search;
            $query->whereHasMorph('causer', [User::class], function ($q) use ($term) {
                $q->where('name', 'like', "%{$term}%")
                    ->orWhere('login_id', 'like', "%{$term}%");
            });
        }

        // 4. Filter by Role of the Causer
        if ($request->filled('role')) {
            $query->whereHasMorph('causer', [User::class], function ($q) use ($request) {
                $q->role($request->role);
            });
        }

        $logs = $query->latest()->paginate(20)->withQueryString();

        // Fetch roles for the dropdown [3]
        $roles = Role::pluck('name', 'name');

        // Define common action types for the dropdown
        $actionTypes = ['created', 'updated', 'deleted', 'auth'];

        return view('admin.activity.index', compact('logs', 'roles', 'actionTypes'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/UserController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\User;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Gate; // FIXED: Added missing facade import
// Added: Required for transaction safety
use Spatie\Permission\Models\Role;

class UserController extends Controller
{
    public function index(Request $request)
    {
        // ARCHITECTURE FIX: Granular Authorization
        Gate::authorize('view_login_credentials');

        $roles = Role::pluck('name', 'name');
        $status = ['active', 'deactive'];

        // ARCHITECTURE FIX: Remove ->whereNull('parent_id') [Addendum 2.a]
        // We now list all Login Credentials, grouped by their linked company.
        $query = User::with(['roles', 'company']);

        if (auth()->user()->hasRole('cs_leader')) {
            $query->whereDoesntHave('roles', fn ($q) => $q->whereIn('name', ['admin', 'cs_leader']));
        }

        if (auth()->user()->hasPermissionTo('view_assigned_customers') &&
            ! auth()->user()->hasAnyRole(['admin', 'cs_leader'])) {
            $query->where('assigned_cs_id', auth()->id());
        }

        $users = $query->search($request->search)
            ->filterByDate()
            ->filterByRole()
            ->latest()
            ->paginate(15)
            ->withQueryString();

        return view('users.index', compact('users', 'roles', 'status'));
    }

    public function assignedIndex(Request $request)
    {
        // ARCHITECTURE FIX: Remove ->whereNull('parent_id') [Addendum 2.a]
        // This fulfills Section 5.a: Viewing assigned customer logins.
        $users = User::where('assigned_cs_id', auth()->id())
            ->with(['roles', 'company'])
            ->search($request->search)
            ->filterByDate()
            ->latest()
            ->paginate(15);

        $roles = ['customer' => 'customer'];

        return view('users.assigned', compact('users', 'roles'));
    }

    /**
     * Fulfills Backbone 2.a & 3.b: Onboard Login Credentials.
     * ARCHITECTURE FIX: Resolved "Undefined variable $parent" by providing context.
     */
    public function create(Request $request)
    {
        Gate::authorize('create_users');

        // 1. Core Data Collections
        $roles = \Spatie\Permission\Models\Role::where('name', '!=', 'admin')->get();
        $companys = \App\Models\Company::orderBy('company_name')->get();
        $csStaffMembers = User::role(['admin', 'cs_leader', 'cs_staff'])->get();

        // 2. ARCHITECTURE FIX: Retrieve parent context if creating a Branch account [Backbone 3.a.2]
        // This resolves the ErrorException at line 4 of the create blade.
        $parent = $request->has('parent_id') ? User::find($request->parent_id) : null;

        return view('users.create', compact('roles', 'csStaffMembers', 'companys', 'parent'));
    }

    /**
     * ARCHITECTURE FIX: Conditional validation for 'company_id'.
     */
    public function store(Request $request)
    {
        Gate::authorize('create_users');

        $request->validate([
            'name' => 'required|string|max:255',
            'login_id' => 'required|string|unique:users',
            'email' => 'required|email|unique:users',
            'password' => 'required|confirmed|min:8',
            'role' => 'required|exists:roles,name',
            // FIX: company_id is ONLY required if the user is a customer [Addendum 2.a]
            'company_id' => 'required_if:role,customer|nullable|exists:companys,id',
        ]);

        $user = User::create([
            'name' => $request->name,
            'login_id' => $request->login_id,
            'email' => $request->email,
            'password' => \Illuminate\Support\Facades\Hash::make($request->password),
            'company_id' => $request->company_id, // Null for non-customer roles
            'status' => 'active',
        ]);

        $user->assignRole($request->role);

        return redirect()->route('users.index')->with('success', 'User login created.');
    }

    public function edit(User $user)
    {
        Gate::authorize('edit_users');

        if ($user->hasRole('admin') && auth()->id() !== $user->id) {
            abort(403, 'System Integrity Lock: Root Admin is immutable.');
        }

        $roles = \Spatie\Permission\Models\Role::where('name', '!=', 'admin')->get();
        $csStaffMembers = User::role(['admin', 'cs_leader', 'cs_staff'])->get();
        $companys = \App\Models\Company::orderBy('company_name')->get();

        // ARCHITECTURE FIX: Determine if assignment is locked based on order existence [Backbone 9.c.1]
        $isAssignmentLocked = $user->orders()->exists();

        return view('users.edit', compact('user', 'roles', 'csStaffMembers', 'companys', 'isAssignmentLocked'));
    }

    /**
     * Fulfills Addendum 3.b: User Management ONLY for Credentials and Company Link.
     * ARCHITECTURE FIX: Purged legacy 'details()' relationship call.
     */
    public function update(Request $request, User $user)
    {
        // 1. Validation scoped strictly to User Credential attributes [Addendum 3.b]
        $request->validate([
            'name' => 'required|string|max:255',
            'email' => 'required|email|unique:users,email,'.$user->id,
            'role' => 'required|exists:roles,name',
            'status' => 'required|in:active,deactive',
            'company_id' => 'required|exists:companys,id', // Fulfills Many-to-One link [2.a]
            'assigned_cs_id' => 'nullable|exists:users,id',
            'password' => 'nullable|min:8|confirmed',
        ]);

        // 2. Prepare Core User Data
        $userData = [
            'name' => $request->name,
            'email' => $request->email,
            'company_id' => $request->company_id, // Direct link to business entity
        ];

        // 3. Security Guard: Only allow status/role changes if target is NOT an admin
        if (! $user->hasRole('admin')) {
            $userData['status'] = $request->status;

            if (auth()->user()->hasPermissionTo('reassign_customers')) {
                $userData['assigned_cs_id'] = $request->assigned_cs_id;
            }

            $user->syncRoles([$request->role]);
        }

        // 4. Handle Optional Password Update
        if ($request->filled('password')) {
            $userData['password'] = \Illuminate\Support\Facades\Hash::make($request->password);
        }

        // 5. Atomic Update to Users Table
        $user->update($userData);

        // ARCHITECTURE FIX: The legacy $user->details() block has been REMOVED.
        // Business data (PIC, Address, etc.) must be updated via CompanyController [3.c].

        if (auth()->user()->hasAnyRole(['admin', 'cs_leader'])) {
            return redirect()->route('users.index')->with('success', 'User credentials updated successfully.');
        }

        return redirect()->route('users.assigned')->with('success', 'Customer login updated.');
    }

    /**
     * Remove the specified user and their branches from storage.
     * Fulfills Requirement: Cascading delete for HQ and Branches if no order history exists.
     * Fulfills Section 3.c: Protects DB records if order history is found.
     */
    public function destroy(User $user)
    {
        // Now resolves correctly to Illuminate\Support\Facades\Gate
        Gate::authorize('edit_users');

        // Refined Section 3.c.1 Check:
        // Verification happens in the Model to ensure clusters are clean.
        if (! $user->canBeDeleted()) {
            return redirect()->back()->with('error', 'This user or its branches have existing order records and cannot be deleted to protect data integrity.');
        }

        DB::transaction(function () use ($user) {
            // Fulfills Request: If HQ is deleted, delete all branches first
            if (is_null($user->parent_id)) {
                $user->branches()->delete();
            }

            $user->delete();
        });

        return redirect()->route('users.index')->with('success', 'User account and associated branches removed successfully.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Controller.php ---
<?php

namespace App\Http\Controllers;

abstract class Controller
{
    //
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/CompanyController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\Catalog;
use App\Models\Company;
use Illuminate\Http\Request; // FIXED: Added missing facade import
use Illuminate\Support\Facades\Gate;

class CompanyController extends Controller
{
    public function index(Request $request)
    {
        Gate::authorize('view_business_entities');

        $companys = Company::with(['catalog', 'parent', 'branches'])
            ->whereNull('parent_id')
            ->when($request->search, function ($q) use ($request) {
                $q->where('company_name', 'like', "%{$request->search}%")
                    ->orWhere('company_code', 'like', "%{$request->search}%");
            })
            ->latest()
            ->paginate(15);

        return view('admin.companys.index', compact('companys'));
    }

    public function create(Request $request)
    {
        $catalogs = Catalog::where('status', 'active')->orderBy('name')->get();
        $hqs = Company::whereNull('parent_id')->orderBy('company_name')->get();

        $preselectedParentId = $request->query('parent_id');
        $preselectedParent = $preselectedParentId ? Company::find($preselectedParentId) : null;

        return view('admin.companys.create', compact('catalogs', 'hqs', 'preselectedParent'));
    }

    /**
     * Fulfills Addendum 1.d: Register HQ or Branch with strict code requirements.
     */
    public function store(Request $request)
    {
        $validated = $request->validate([
            'company_name' => 'required|string|max:255',
            'parent_id' => 'nullable|exists:companys,id',
            'company_code' => ['nullable', 'required_without:parent_id', 'unique:companys,company_code'],
            'branch_code' => ['nullable', 'required_with:parent_id', 'unique:companys,branch_code'],
            'catalog_id' => 'nullable|exists:catalogs,id',
            'company_reg_no' => 'nullable|string|max:255',
            'pic_name' => 'nullable|string|max:255',
            'pic_phone' => 'nullable|string|max:255',
            'delivery_address' => 'required|string',
            'postal_code' => 'nullable|string|max:10',
            'city' => 'nullable|string|max:100',
            'state' => 'nullable|string|max:100',
        ]);

        Company::create($validated);

        return redirect()->route('companys.index')->with('success', 'Business entity registered successfully.');
    }

    public function edit(Company $company)
    {
        $catalogs = Catalog::where('status', 'active')->get();

        return view('admin.companys.edit', compact('company', 'catalogs'));
    }

    /**
     * ARCHITECTURE FIX: Security Lockdown.
     * Block the user from updating uneditable fields (Identity & Hierarchy).
     */
    public function update(Request $request, Company $company)
    {
        // 1. Validate ONLY the fields allowed to be changed [Addendum 3.c]
        $validated = $request->validate([
            'catalog_id' => 'nullable|exists:catalogs,id',
            'company_reg_no' => 'nullable|string|max:255',
            'pic_name' => 'nullable|string|max:255',
            'pic_phone' => 'nullable|string|max:255',
            'delivery_address' => 'required|string',
            'postal_code' => 'nullable|string|max:10',
            'city' => 'nullable|string|max:100',
            'state' => 'nullable|string|max:100',
        ]);

        // 2. SECURITY GUARD: Explicitly exclude identity fields from the request
        // to prevent forged POST injections of 'company_name', 'company_code', or 'parent_id'.
        $updateData = $request->only([
            'catalog_id', 'company_reg_no', 'pic_name', 'pic_phone',
            'delivery_address', 'postal_code', 'city', 'state',
        ]);

        $company->update($updateData);

        return redirect()->route('companys.index')->with('success', 'Business logistics and contact updated.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Auth/NewPasswordController.php ---
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use App\Models\User;
use Illuminate\Auth\Events\PasswordReset;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Facades\Password;
use Illuminate\Support\Str;
use Illuminate\Validation\Rules;
use Illuminate\View\View;

class NewPasswordController extends Controller
{
    /**
     * Display the password reset view.
     */
    public function create(Request $request): View
    {
        return view('auth.reset-password', ['request' => $request]);
    }

    /**
     * Handle an incoming new password request.
     *
     * @throws \Illuminate\Validation\ValidationException
     */
    public function store(Request $request): RedirectResponse
    {
        $request->validate([
            'token' => ['required'],
            'email' => ['required', 'email'],
            'password' => ['required', 'confirmed', Rules\Password::defaults()],
        ]);

        // Here we will attempt to reset the user's password. If it is successful we
        // will update the password on an actual user model and persist it to the
        // database. Otherwise we will parse the error and return the response.
        $status = Password::reset(
            $request->only('email', 'password', 'password_confirmation', 'token'),
            function (User $user) use ($request) {
                $user->forceFill([
                    'password' => Hash::make($request->password),
                    'remember_token' => Str::random(60),
                ])->save();

                event(new PasswordReset($user));
            }
        );

        // If the password was successfully reset, we will redirect the user back to
        // the application's home authenticated view. If there is an error we can
        // redirect them back to where they came from with their error message.
        return $status == Password::PASSWORD_RESET
                    ? redirect()->route('login')->with('status', __($status))
                    : back()->withInput($request->only('email'))
                        ->withErrors(['email' => __($status)]);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Auth/PasswordResetLinkController.php ---
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Password;
use Illuminate\View\View;

class PasswordResetLinkController extends Controller
{
    /**
     * Display the password reset link request view.
     */
    public function create(): View
    {
        return view('auth.forgot-password');
    }

    /**
     * Handle an incoming password reset link request.
     *
     * @throws \Illuminate\Validation\ValidationException
     */
    public function store(Request $request): RedirectResponse
    {
        $request->validate([
            'email' => ['required', 'email'],
        ]);

        // We will send the password reset link to this user. Once we have attempted
        // to send the link, we will examine the response then see the message we
        // need to show to the user. Finally, we'll send out a proper response.
        $status = Password::sendResetLink(
            $request->only('email')
        );

        return $status == Password::RESET_LINK_SENT
                    ? back()->with('status', __($status))
                    : back()->withInput($request->only('email'))
                        ->withErrors(['email' => __($status)]);
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Auth/PasswordController.php ---
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Hash;
use Illuminate\Validation\Rules\Password;

class PasswordController extends Controller
{
    /**
     * Update the user's password.
     */
    public function update(Request $request): RedirectResponse
    {
        $validated = $request->validateWithBag('updatePassword', [
            'current_password' => ['required', 'current_password'],
            'password' => ['required', Password::defaults(), 'confirmed'],
        ]);

        $request->user()->update([
            'password' => Hash::make($validated['password']),
        ]);

        return back()->with('status', 'password-updated');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Auth/AuthenticatedSessionController.php ---
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use App\Http\Requests\Auth\LoginRequest;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\View\View;

class AuthenticatedSessionController extends Controller
{
    /**
     * Display the login view.
     */
    public function create(): View
    {
        return view('auth.login');
    }

    /**
     * Handle an incoming authentication request.
     */
    public function store(LoginRequest $request): RedirectResponse
    {
        $request->authenticate();

        $request->session()->regenerate();

        // Manual Log for Login Activity
        activity('auth')
            ->performedOn(auth()->user())
            ->causedBy(auth()->user())
            ->log('User logged into the system');

        return redirect()->intended(route('dashboard', absolute: false));
    }

    /**
     * Destroy an authenticated session.
     */
    public function destroy(Request $request): RedirectResponse
    {
        Auth::guard('web')->logout();

        $request->session()->invalidate();

        $request->session()->regenerateToken();

        return redirect('/');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/DashboardController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\Order;
use Illuminate\Support\Facades\Auth;

class DashboardController extends Controller
{
    /**
     * Fulfills Addendum Section 4: Unified Order Dashboard
     * Updated to support Staff-Specific Scoping per user request.
     */
    public function index()
    {
        $user = Auth::user();

        if ($user->hasAnyRole(['admin', 'cs_leader', 'cs_staff'])) {

            // ARCHITECTURE FIX: Initialize scoped query based on current staff [Section 5.a]
            $baseQuery = Order::assignedTo($user);

            // Clone the scoped query for each status to ensure accurate real-time counts
            $stats = [
                'All Orders' => (clone $baseQuery)->count(),
                'Pending' => (clone $baseQuery)->where('status', 'pending')->count(),
                'Approved' => (clone $baseQuery)->where('status', 'approved')->count(),
                'In Transit' => (clone $baseQuery)->where('status', 'in_transit')->count(),
                'Delivered' => (clone $baseQuery)->where('status', 'completed')->count(),
                'Cancelled' => (clone $baseQuery)->where('status', 'cancelled')->count(),
            ];

            return view('cs.orders.dashboard', compact('stats'));
        }

        // Standard landing page for Customers [Backbone Section 1.b]
        return view('dashboard');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/CatalogController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\Catalog;
use App\Models\Item;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Gate;

class CatalogController extends Controller
{
    public function index(Request $request)
    {
        Gate::authorize('view_catalogs');

        $query = Catalog::query();

        if ($request->filled('search')) {
            $query->search($request->search); // Uses Searchable trait [1]
        }

        $catalogs = $query->withCount('items')->latest()->paginate(10)->withQueryString();

        return view('admin.catalogs.index', compact('catalogs'));
    }

    public function create()
    {
        // Requirement: Needs View + Create
        if (! auth()->user()->can('view_catalogs') || ! auth()->user()->can('create_catalogs')) {
            abort(403);
        }

        return view('admin.catalogs.create');
    }

    public function store(Request $request)
    {
        // Requirement: Needs View + Create + Edit
        if (! auth()->user()->can('view_catalogs') ||
            ! auth()->user()->can('create_catalogs') ||
            ! auth()->user()->can('edit_catalogs')) {
            abort(403);
        }

        $validated = $request->validate([
            'name' => 'required|string|max:255|unique:catalogs,name',
        ]);

        Catalog::create($validated);

        return redirect()->route('catalogs.index')->with('success', 'Catalog created successfully.');
    }

    public function edit(Catalog $catalog)
    {
        // Requirement: Needs View + Create + Edit
        if (! auth()->user()->can('view_catalogs') ||
            ! auth()->user()->can('create_catalogs') ||
            ! auth()->user()->can('edit_catalogs')) {
            abort(403);
        }

        // Fetch all items to populate the Whitelist Interface [2]
        $items = Item::orderBy('name')->get();

        // Get IDs of items already in this catalog for checkbox states
        $assignedItemIds = $catalog->items()->pluck('items.id')->toArray();

        return view('admin.catalogs.edit', compact('catalog', 'items', 'assignedItemIds'));
    }

    public function update(Request $request, Catalog $catalog)
    {
        if (! auth()->user()->can('view_catalogs') || ! auth()->user()->can('create_catalogs') || ! auth()->user()->can('edit_catalogs')) {
            abort(403);
        }

        $validated = $request->validate([
            'name' => 'required|string|max:255|unique:catalogs,name,'.$catalog->id,
            'items' => 'nullable|array',
            'items.*' => 'exists:items,id',
            'status' => 'sometimes|in:active,deactive',
        ]);

        $catalog->update([
            'name' => $validated['name'],
            'status' => $validated['status'] ?? $catalog->status,
        ]);

        // FIX: Only sync items if the whitelist data is present in the request
        if ($request->has('items')) {
            $catalog->items()->sync($request->input('items', []));
        }

        return redirect()->route('catalogs.index')->with('success', 'Catalog updated successfully.');
    }

    public function destroy(Catalog $catalog)
    {
        Gate::authorize('edit_catalogs');

        if (! $catalog->canBeDeleted()) {
            return redirect()->back()->with('error', 'Cannot delete catalog while customers are assigned to it.');
        }

        $catalog->delete();

        return redirect()->route('catalogs.index')->with('success', 'Catalog removed.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/CS/OrderManagementController.php ---
<?php

namespace App\Http\Controllers\CS;

use App\Http\Controllers\Controller;
use App\Models\Order; // Added: Fulfills Section 5 Handover Context
use App\Models\User; // Added: Required for form handling
use Illuminate\Http\Request;
use Illuminate\Support\Facades\DB;

class OrderManagementController extends Controller
{
    /**
     * Fulfills Section 5.a: On-going Orders
     * Displays orders assigned to me or currently handled by me that are in active transit states.
     */
    public function index(Request $request)
    {
        $user = auth()->user();

        // ARCHITECTURE FIX: Define statuses for the dropdown requested by Blade [3]
        $status = ['pending', 'approved', 'in_transit'];

        $query = Order::whereIn('status', $status)
            ->where(function ($query) use ($user) {
                $query->where('handler_id', $user->id)
                    ->orWhere(function ($sub) use ($user) {
                        $sub->whereNull('handler_id')
                            ->whereHas('user', function ($u) use ($user) {
                                $u->where('assigned_cs_id', $user->id);
                            });
                    });
            });

        // Apply Dynamic Search [1, 5]
        if ($request->filled('search')) {
            $term = $request->search;
            $query->where(function ($q) use ($term) {
                $q->search($term)
                    ->orWhereHas('user', fn ($u) => $u->where('name', 'like', "%{$term}%"));
            });
        }

        // ARCHITECTURE FIX: Apply the Status Filter from the dynamic dropdown
        if ($request->filled('status') && in_array($request->status, $status)) {
            $query->where('status', $request->status);
        }

        // Finalize with Pagination and Query String Persistence
        $myOrders = $query->latest()
            ->paginate(15)
            ->withQueryString();

        // Pass $status to resolve the ErrorException in the Blade view [3]
        return view('cs.orders.index', compact('myOrders', 'status'));
    }

    /**
     * Fulfills Section 5.b: Claiming Queue (Unassigned Orders)
     * Displays orders from customers who have NO assigned CS Staff.
     */
    public function queue(Request $request) // Inject Request
    {
        $query = Order::where('status', 'pending')
            ->whereNull('handler_id')
            ->whereHas('user', function ($q) {
                $q->whereNull('assigned_cs_id');
            });

        // ARCHITECTURE FIX: Enable search by Order # or Customer Name
        if ($request->filled('search')) {
            $term = $request->search;
            $query->where(function ($q) use ($term) {
                $q->search($term) // Hits order_number [12]
                    ->orWhereHas('user', fn ($u) => $u->where('name', 'like', "%{$term}%"));
            });
        }

        $unassigned = $query->latest()->paginate(15)->withQueryString();

        return view('cs.orders.queue', compact('unassigned'));
    }

    /**
     * Fulfills Section 5: Handler Visibility & Handover Context
     */
    public function show(Order $order)
    {
        // ARCHITECTURE FIX: Change 'user.details' to 'user.company' [Addendum 1.a]
        // Also load 'items.uom' to ensure unit names display correctly in the CS view.
        $order->load(['items.item', 'items.uom', 'user.company', 'handler']);

        $eligibleStaff = User::role(['admin', 'cs_leader', 'cs_staff'])
            ->where('id', '!=', auth()->id())
            ->where('status', 'active')
            ->get();

        return view('cs.orders.show', compact('order', 'eligibleStaff'));
    }

    /**
     * Fulfills Section 5: Handover Protocol (CS A to CS B) [5]
     */
    public function handover(Request $request, Order $order)
    {
        $request->validate([
            'new_handler_id' => 'required|exists:users,id',
        ]);

        $oldHandlerName = $order->handler->name ?? 'Unassigned';
        $newHandler = User::findOrFail($request->new_handler_id);

        // Security: Only the current handler or a Leader/Admin can initiate handover [5, 6]
        if ($order->handler_id !== auth()->id() && ! auth()->user()->hasAnyRole(['admin', 'cs_leader'])) {
            abort(403, 'Unauthorized handover attempt.');
        }

        $order->update(['handler_id' => $newHandler->id]);

        activity('order')
            ->performedOn($order)
            ->causedBy(auth()->user())
            ->log("Order handed over from {$oldHandlerName} to {$newHandler->name}");

        return redirect()->route('office.orders.index')->with('success', "Order handed over to {$newHandler->name}.");
    }

    /**
     * Fulfills Ownership Logic and Section 5.a Permanent Cluster Assignment
     */
    public function claim(Order $order)
    {
        if ($order->handler_id) {
            return redirect()->back()->with('error', 'This order has already been claimed.');
        }

        DB::transaction(function () use ($order) {
            // 1. Claim the specific order
            $order->update(['handler_id' => auth()->id()]);

            // 2. Fulfills Section 5.a Cluster Logic:
            // If the HQ is unassigned, assign the entire hierarchy to this CS
            $customer = $order->user;

            // Find the "Root HQ" (The user themselves if they have no parent)
            $hq = $customer->parent_id ? $customer->parent : $customer;

            if (is_null($hq->assigned_cs_id)) {
                // Assign the HQ
                $hq->update(['assigned_cs_id' => auth()->id()]);

                // Assign all associated branches
                $hq->branches()->update(['assigned_cs_id' => auth()->id()]);

                activity('user_assignment')
                    ->performedOn($hq)
                    ->causedBy(auth()->user())
                    ->log("Entire HQ Cluster ({$hq->name} and branches) assigned to CS: ".auth()->user()->name);
            }
        });

        activity('order')
            ->performedOn($order)
            ->causedBy(auth()->user())
            ->log('Order claimed by CS Staff');

        return redirect()->back()->with('success', 'Order claimed. You are now the assigned representative for this entire customer hierarchy.');
    }

    /**
     * Fulfills Addendum 5.a: UOM Snapshot during Approval
     */
    public function approve(Order $order)
    {
        $this->authorizeAction($order);

        \Illuminate\Support\Facades\DB::transaction(function () use ($order) {
            foreach ($order->items as $orderItem) {
                $uom = $orderItem->uom;

                // ARCHITECTURE FIX: Strictly use UOM price. Fail if UOM is missing
                // to prevent RM 0.00 data corruption in snapshots [Addendum 5.a]
                $orderItem->update([
                    'snapshot_name' => $orderItem->item->name,
                    'snapshot_uom_name' => $uom?->uom_name ?? 'Unit',
                    'snapshot_uom_rate' => $uom?->rate_qty ?? 1,
                    'price_at_order' => $uom->price, // REMOVED legacy price fallback
                ]);
            }
            $order->update(['status' => 'approved']);
        });

        return redirect()->back()->with('success', 'Order approved and Pure UOM prices snapshotted.');
    }

    /**
     * Fulfills Addendum 4.b: Filtered list for Leaders to approve cancellations.
     */
    public function cancellationRequests(Request $request)
    {
        $query = Order::where('status', 'cancellation_requested')
            ->with(['user.company', 'handler', 'cancellationRequester']);

        if ($request->filled('search')) {
            $term = $request->search;
            $query->where(function ($q) use ($term) {
                $q->search($term)
                    ->orWhereHas('user', fn ($u) => $u->where('name', 'like', "%{$term}%"));
            });
        }

        $requests = $query->latest()->paginate(15)->withQueryString();

        return view('cs.orders.cancellations', compact('requests'));
    }

    /**
     * Fulfills Addendum 4.a & 4.b: Strict Role-Based Cancellation.
     */
    public function cancel(\App\Http\Requests\CS\CancelOrderRequest $request, Order $order)
    {
        $user = auth()->user();
        $this->authorizeAction($order);

        // LOGIC FIX: Handle Approved Order -> Request Transition
        if ($order->status === 'approved' && $user->hasRole('cs_staff')) {
            $order->update([
                'status' => 'cancellation_requested',
                'cancellation_requested_by' => $user->id,
                'cancellation_request_reason' => $request->cancellation_reason,
            ]);

            return redirect()->route('office.orders.show', $order)->with('success', 'Cancellation request submitted for manager approval.');
        }

        // SECURITY FIX: Explicitly block CS Staff from finalizing cancellations [Addendum 4.b]
        if ($order->status === 'cancellation_requested' && $user->hasRole('cs_staff')) {
            abort(403, 'Unauthorized: CS Staff cannot finalize cancellation requests.');
        }

        // Only Admin/Leader reaches here to finalize
        $order->update([
            'status' => 'cancelled',
            'cancellation_reason' => $request->cancellation_reason ?? $order->cancellation_request_reason,
            'cancellation_requested_by' => $order->cancellation_requested_by ?? $user->id,
        ]);

        return redirect()->route('office.orders.index')->with('success', 'Order has been permanently cancelled.');
    }

    /**
     * Fulfills Section 4.4 & 6: In Transit Status & Internal Notes
     */
    public function updateStatus(Request $request, Order $order)
    {
        // Security: Only handler or CS Leader/Admin [5]
        if ($order->handler_id !== auth()->id() && ! auth()->user()->hasAnyRole(['admin', 'cs_leader'])) {
            abort(403);
        }

        $validated = $request->validate([
            // FIX: Added 'pending' to the allowed list so notes can be saved early [1, 3]
            'status' => 'required|in:pending,approved,in_transit,completed',
            'internal_notes' => 'nullable|string',
            'tracking_number' => 'required_if:status,in_transit|nullable|string',
            'logistics_carrier' => 'required_if:status,in_transit|nullable|string',
        ]);

        $order->update($validated);

        activity('order')
            ->performedOn($order)
            ->causedBy(auth()->user())
            ->log("Order updated (Status: {$request->status})");

        return redirect()->back()->with('success', 'Internal notes updated successfully.');
    }

    /**
     * Fulfills Section 5.c: My Claimed Orders (Master List)
     * Displays all orders ever claimed by this CS, providing a full historical audit trail.
     */
    public function history(Request $request) // Added Request injection
    {
        $user = auth()->user();

        // Define the statuses available for filtering
        $status = ['draft', 'pending', 'approved', 'in_transit', 'completed', 'cancelled'];

        // 1. Initialize query scoped to the current handler [Section 5.c]
        $query = \App\Models\Order::where('handler_id', $user->id);

        // 2. Apply Dynamic Search (Order Number or Customer Name)
        if ($request->filled('search')) {
            $term = $request->search;
            $query->where(function ($q) use ($term) {
                $q->search($term) // Uses Searchable trait [4]
                    ->orWhereHas('user', fn ($u) => $u->where('name', 'like', "%{$term}%"));
            });
        }

        // 3. ARCHITECTURE FIX: Apply the Status Filter from the dropdown
        if ($request->filled('status') && in_array($request->status, $status)) {
            $query->where('status', $request->status);
        }

        // 4. Finalize with Pagination and Query String Persistence
        $history = $query->latest()
            ->paginate(15)
            ->withQueryString(); // Prevents losing filters when clicking "Page 2" [5]

        return view('cs.orders.history', compact('history', 'status'));
    }

    /**
     * Fulfills Section 5.d Handover Protocol & Ownership Logic.
     * Ensures only the current handler or an elevated role can execute state changes.
     */
    private function authorizeAction(Order $order): void
    {
        $user = auth()->user();

        // Allow Admin and CS Leaders full authority over all orders [Backbone 2.a, 2.b]
        if ($user->hasAnyRole(['admin', 'cs_leader'])) {
            return;
        }

        // CS Staff can only process orders where they are the explicit handler [Section 5.c]
        if ($order->handler_id !== $user->id) {
            abort(403, 'Read-Only Mode: You are not the assigned handler for this order.');
        }
    }

    /**
     * Fulfills Leadership Oversight Requirement.
     * Displays ALL system orders with advanced filtering.
     */
    public function allOrders(Request $request)
    {
        // SECURITY GUARD: Leadership tier only [Backbone 2.a, 2.b]
        if (! auth()->user()->hasAnyRole(['admin', 'cs_leader'])) {
            abort(403, 'Unauthorized: Master oversight restricted to Leadership.');
        }

        $status = ['draft', 'pending', 'approved', 'in_transit', 'completed', 'cancelled', 'cancellation_requested'];

        // ARCHITECTURE FIX: Deep Eager Loading to resolve company and handler identity [Addendum 1.a]
        $query = Order::with(['user.company', 'handler']);

        // ARCHITECTURE FIX: Multi-Entity Search (Order #, Customer Name, or Handler Name)
        if ($request->filled('search')) {
            $term = $request->search;
            $query->where(function ($q) use ($term) {
                $q->search($term) // Hits order_number via Searchable trait
                    ->orWhereHas('user', fn ($u) => $u->where('name', 'like', "%{$term}%"))
                    ->orWhereHas('handler', fn ($h) => $h->where('name', 'like', "%{$term}%"));
            });
        }

        // Apply Status Filter
        if ($request->filled('status') && in_array($request->status, $status)) {
            $query->where('status', $request->status);
        }

        $allOrders = $query->latest()->paginate(15)->withQueryString();

        return view('cs.orders.all', compact('allOrders', 'status'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Admin/RoleController.php ---
<?php

namespace App\Http\Controllers\Admin;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use Spatie\Permission\Models\Role;

class RoleController extends Controller
{
    /**
     * List all roles. Fulfills Backbone 2.f (Custom Roles).
     */
    public function index()
    {
        $roles = Role::withCount('users')->get();
        // Core roles that cannot be deleted to maintain system logic integrity
        $protectedRoles = ['admin', 'cs_leader', 'cs_staff', 'customer'];

        return view('admin.roles.index', compact('roles', 'protectedRoles'));
    }

    /**
     * Fulfills Requirement: Block "Admin" role creation.
     */
    public function store(Request $request)
    {
        $request->validate([
            'name' => [
                'required',
                'string',
                'unique:roles,name',
                // SECURITY GUARD: No one, including current admin, can create another admin role
                'not_in:admin,Admin,ADMIN',
            ],
        ]);

        Role::create(['name' => strtolower($request->name), 'guard_name' => 'web']);

        return redirect()->route('admin.roles.manage.index')->with('success', 'Custom role established.');
    }

    /**
     * Prevent deletion of system-critical roles.
     */
    public function destroy(Role $role)
    {
        $protectedRoles = ['admin', 'cs_leader', 'cs_staff', 'customer'];

        if (in_array($role->name, $protectedRoles)) {
            return redirect()->back()->with('error', 'System Integrity Violation: Protected roles cannot be removed.');
        }

        if ($role->users()->count() > 0) {
            return redirect()->back()->with('error', 'Role is currently assigned to active users.');
        }

        $role->delete();

        return redirect()->route('admin.roles.manage.index')->with('success', 'Role removed.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/ProfileController.php ---
<?php

namespace App\Http\Controllers;

use App\Http\Requests\ProfileUpdateRequest;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Redirect;
use Illuminate\View\View;

class ProfileController extends Controller
{
    /**
     * Display the user's profile form.
     */
    public function edit(Request $request): View
    {
        // ARCHITECTURE FIX: Eager load Company and CS Rep to prevent N+1 in profile view.
        $user = $request->user()->load(['company', 'csRepresentative', 'roles']);

        return view('profile.edit', [
            'user' => $user,
        ]);
    }

    /**
     * Update the user's profile information.
     */
    public function update(ProfileUpdateRequest $request): RedirectResponse
    {
        $request->user()->fill($request->validated());

        if ($request->user()->isDirty('email')) {
            $request->user()->email_verified_at = null;
        }

        $request->user()->save();

        return Redirect::route('profile.edit')->with('status', 'profile-updated');
    }

    /**
     * Delete the user's account.
     */
    public function destroy(Request $request): RedirectResponse
    {
        $request->validateWithBag('userDeletion', [
            'password' => ['required', 'current_password'],
        ]);

        $user = $request->user();

        Auth::logout();

        $user->delete();

        $request->session()->invalidate();
        $request->session()->regenerateToken();

        return Redirect::to('/');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/ItemController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\Item;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Gate;
use Illuminate\Support\Facades\Storage;
use App\Models\Category;
use App\Models\Catalog;
use Illuminate\Support\Facades\DB; // ARCHITECTURE FIX: Added missing DB Facade import
use Illuminate\Http\RedirectResponse; // ARCHITECTURE FIX: Resolved TypeError by importing framework class
use App\Models\Uom;

// Note: For actual compression, you would typically use 'Intervention Image' library
// composer require intervention/image

class ItemController extends Controller
{
    /**
     * Fulfills Requirement: Master Item Registry oversight.
     * ARCHITECTURE FIX: Removed price logic; optimized for status visibility.
     */
    public function index(Request $request)
    {
        Gate::authorize('view_items');

        $query = Item::query();

        // Multi-attribute search (SKU or Name)
        if ($request->filled('search')) {
            $query->where(function ($q) use ($request) {
                $q->where('name', 'like', "%{$request->search}%")
                  ->orWhere('sku', 'like', "%{$request->search}%");
            });
        }

        // ARCHITECTURE FIX: Pricing is now in UOMs. Removed sorting by 'price' [Addendum 5.a].
        // Eager load UOMs and Catalogs for performance.
        $items = $query->with(['activeUoms', 'catalogs'])
            ->latest()
            ->paginate(15)
            ->withQueryString();

        return view('admin.items.index', compact('items'));
    }

    public function create()
    {
        Gate::authorize('create_items');

        // ARCHITECTURE FIX: Fetch all catalogs to enable item-side whitelisting
        $catalogs = \App\Models\Catalog::orderBy('name')->get();

        return view('admin.items.create', compact('catalogs'));
    }

    /**
     * ARCHITECTURE FIX: Atomic Product Initialization.
     * Fulfills Requirement: Nested UOM persistence during Item creation [11.a].
     */
    public function store(Request $request): RedirectResponse
    {
        Gate::authorize('create_items');

        // 1. HARDENED VALIDATION [Backbone 5.c]
        $validated = $request->validate([
            'name'         => ['required', 'string', 'max:255'],
            'sku'          => ['required', 'string', 'unique:items,sku'],
            'description'  => ['nullable', 'string'],
            'status'       => ['required', 'in:active,inactive'],
            'image'        => ['nullable', 'image', 'mimes:jpeg,png,jpg,webp', 'max:2048'],

            // Whitelist Sync Arrays
            'categories'   => ['nullable', 'array'],
            'categories.*' => ['exists:categories,id'],
            'catalogs'     => ['nullable', 'array'],
            'catalogs.*'   => ['exists:catalogs,id'],

            // UOM Array Validation [Pure UOM Model]
            'uoms'            => ['required', 'array', 'min:1'], // Fulfills Base-Unit Guard [4.a.3]
            'uoms.*.uom_name' => ['required', 'string', 'max:50'],
            'uoms.*.rate_qty' => ['required', 'numeric', 'min:1'],
            'uoms.*.price'    => ['required', 'numeric', 'min:0'],
            'uoms.*.status'   => ['required', 'in:active,inactive'],
        ], [
            'uoms.required' => __('You must initialize at least one packaging unit (Base Unit Rate 1) for catalog visibility.')
        ]);

        // 2. ATOMIC TRANSACTION GUARD [Backbone 11.a]
        DB::transaction(function () use ($request, $validated) {

            // Create Core Identity
            $item = Item::create($request->only(['name', 'sku', 'description', 'status']));

            // Handle Media
            if ($request->hasFile('image')) {
                $path = $request->file('image')->store('items', 'public');
                $item->update(['image_path' => $path]);
            }

            // Sync Whitelist Assignments [Backbone 3.a.3]
            $item->categories()->sync($validated['categories'] ?? []);
            $item->catalogs()->sync($validated['catalogs'] ?? []);

            // 3. PERSIST PACKAGING TIERS (The Missing Link)
            // We use createMany to efficiently insert the nested array into the uoms table.
            $item->uoms()->createMany($validated['uoms']);
        });

        return redirect()->route('items.index')
            ->with('success', __('Product entity and packaging configurations successfully registry-initialized.'));
    }

    /**
 * Fulfills Requirement: Advanced Assignment with Whitelist Oversight.
 */
    public function edit(Item $item): \Illuminate\View\View
    {
        Gate::authorize('edit_items');

        // ARCHITECTURE FIX: Eager load relationships to prevent N+1 queries.
        // Loads Categories, Catalogs, and UOMs for the Pure UOM Pricing Model.
        $item->load(['categories', 'catalogs', 'activeUoms']);

        $categories = Category::where('status', 'active')->orderBy('name')->get();
        $catalogs = Catalog::where('status', 'active')->orderBy('name')->get();

        return view('admin.items.edit', compact('item', 'categories', 'catalogs'));
    }

    /**
     * ARCHITECTURE FIX: Nested UOM CRUD with Status Synchronization.
     * Resolves persistence failure by standardizing on 'inactive' [3.c.1].
     */
    public function update(Request $request, Item $item): \Illuminate\Http\RedirectResponse
    {
        Gate::authorize('edit_items');

        $validated = $request->validate([
            'name'        => ['required', 'string', 'max:255'],
            'sku'         => ['required', 'string', 'unique:items,sku,' . $item->id],
            'status'      => ['required', 'in:active,inactive'],
            'categories'  => ['nullable', 'array'],
            'catalogs'    => ['nullable', 'array'],

            // Nested UOM Validation
            'uoms'             => ['nullable', 'array'],
            'uoms.*.id'        => ['nullable', 'exists:uoms,id'],
            'uoms.*.uom_name'  => ['required_with:uoms', 'string', 'max:50'],
            'uoms.*.rate_qty'  => ['required_with:uoms', 'numeric', 'min:1'],
            'uoms.*.price'     => ['required_with:uoms', 'numeric', 'min:0'],
            'uoms.*.status'    => ['required_with:uoms', 'in:active,inactive'], // Accept both for transition
        ]);

        \Illuminate\Support\Facades\DB::transaction(function () use ($item, $request, $validated) {
            // 1. Sync Core Attributes
            $item->update($request->only(['name', 'sku', 'description', 'status']));

            // 2. Whitelist Syncing [4.a.3]
            $item->categories()->sync($validated['categories'] ?? []);
            $item->catalogs()->sync($validated['catalogs'] ?? []);

            // 3. Process UOM Lifecycle
            $incomingUomIds = collect($validated['uoms'] ?? [])->pluck('id')->filter()->toArray();

            // Deletion Guard: Preserve historical snapshots [6.b]
            $uomsToRemove = $item->uoms()->whereNotIn('id', $incomingUomIds)->get();
            foreach ($uomsToRemove as $oldUom) {
                if ($oldUom->orderItems()->exists()) {
                    $oldUom->update(['status' => 'inactive']);
                } else {
                    $oldUom->delete();
                }
            }

            // 4. Persistence with Strict String Binding
            foreach ($validated['uoms'] ?? [] as $uomData) {
                // MAPPER: Harmonize frontend 'deactive' to architectural 'inactive'
                $statusValue = ($uomData['status'] === 'active') ? 'active' : 'inactive';

                $item->uoms()->updateOrCreate(
                    ['id' => $uomData['id'] ?? null],
                    [
                        'uom_name' => strtoupper($uomData['uom_name']),
                        'rate_qty' => $uomData['rate_qty'],
                        'price'    => $uomData['price'],
                        'status'   => (string) $statusValue,
                    ]
                );
            }
        });

        return redirect()->route('items.index')
            ->with('success', __('Product entity and UOM configurations successfully registry-hardened.'));
    }

    public function destroy(Item $item)
    {
        // Requirement 3C: Deletion Restriction Logic [2]
        if (! $item->canBeDeleted()) {
            return redirect()->back()->with('error', 'Item has transactions and cannot be deleted.');
        }

        if ($item->image_path) {
            Storage::disk('public')->delete($item->image_path);
        }

        $item->delete();

        return redirect()->route('items.index')->with('success', 'Item deleted successfully.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/CategoryController.php ---
<?php

namespace App\Http\Controllers;

use App\Models\Category;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Gate;
use Illuminate\Http\RedirectResponse;
use Illuminate\View\View;
use Illuminate\Validation\Rule;

class CategoryController extends Controller
{
    /**
     * Fulfills Requirement: Permission-gated Registry.
     */
    public function index(Request $request): View
    {
        Gate::authorize('view_items');

        $query = Category::query();

        if ($request->filled('search')) {
            $query->where('name', 'like', "%{$request->search}%");
        }

        // Optimized with Item Counts for oversight performance [Backbone 15.a]
        $categories = $query->withCount('items')
            ->latest()
            ->paginate(15)
            ->withQueryString();

        return view('admin.categories.index', compact('categories'));
    }

    public function create(): View
    {
        Gate::authorize('create_items');
        return view('admin.categories.create');
    }

    public function store(Request $request): RedirectResponse
    {
        Gate::authorize('create_items');

        $validated = $request->validate([
            'name'   => ['required', 'string', 'max:255', 'unique:categories,name'],
            'status' => ['required', 'in:active,deactive'],
        ]);

        Category::create($validated);

        return redirect()->route('categories.index')
            ->with('success', __('Category successfully initialized.'));
    }

    /**
     * Fulfills Requirement: Edit with Deletion Guard Logic [Backbone 9.c.1].
     */
    public function edit(Category $category): View
    {
        Gate::authorize('edit_items');

        // ARCHITECTURE CHECK: Permissibility of Hard Deletion.
        // Restricted if items within this category are part of an Approved/Completed order.
        $canBeDeleted = !$category->items()->whereHas('orderItems.order', function ($q) {
            $q->whereIn('status', ['approved', 'completed']);
        })->exists();

        return view('admin.categories.edit', compact('category', 'canBeDeleted'));
    }

    /**
     * ARCHITECTURE FIX: Secure Update Protocol.
     */
    public function update(Request $request, Category $category): RedirectResponse
    {
        Gate::authorize('edit_items');

        $validated = $request->validate([
            'name'   => ['required', 'string', 'max:255', Rule::unique('categories')->ignore($category->id)],
            'status' => ['required', 'in:active,deactive'],
        ]);

        $category->update($validated);

        return redirect()->route('categories.index')
            ->with('success', __('Category configuration updated.'));
    }

    /**
     * ARCHITECTURE GUARD: Data Integrity Policy [Backbone 9.c.1].
     */
    public function destroy(Category $category): RedirectResponse
    {
        Gate::authorize('edit_items');

        // Secondary server-side security re-check
        $hasHistory = $category->items()->whereHas('orderItems.order', function ($q) {
            $q->whereIn('status', ['approved', 'completed']);
        })->exists();

        if ($hasHistory) {
            return redirect()->back()->with('error', __('Security Violation: Transaction records exist. Use "Inactive" status to hide instead.'));
        }

        $category->delete();

        return redirect()->route('categories.index')
            ->with('success', __('Category purged from registry.'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/RoleManagerController.php ---
<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;
use Spatie\Permission\Models\Permission;
use Spatie\Permission\Models\Role;

class RoleManagerController extends Controller
{
    // 1. SHOW THE MATRIX
    public function index()
    {
        // OLD: $roles = Role::where('name', '!=', 'customer')->get();
        // NEW: Get ALL roles, including customer
        $roles = Role::all();

        // Get all Permissions (Features)
        $permissions = Permission::all();

        return view('admin.roles.matrix', compact('roles', 'permissions'));
    }

    // 2. UPDATE PERMISSIONS
    public function update(Request $request)
    {
        $matrix = $request->input('matrix', []);

        // OLD: $roles = Role::where('name', '!=', 'customer')->get();
        // NEW: Loop through ALL roles so we can save customer settings too
        $roles = Role::all();

        foreach ($roles as $role) {
            // 新增：如果是 admin 角色，跳过权限同步，确保其始终拥有最高权限 [1, 6]
            if ($role->name === 'admin') {
                continue;
            }

            $permissionsForRole = $matrix[$role->id] ?? [];
            $permissionNames = Permission::whereIn('id', $permissionsForRole)->pluck('name');
            $role->syncPermissions($permissionNames);
        }

        return redirect()->back()->with('success', 'Permissions updated successfully!');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Customer/ReservationController.php ---
<?php

namespace App\Http\Controllers\Customer;

use App\Http\Controllers\Controller;
use App\Http\Requests\Customer\AddToCartRequest;
use App\Models\Item;
use App\Models\OrderItem;
use Illuminate\Http\Request;

class ReservationController extends Controller
{
    /**
     * View the current draft contents.
     */
    public function index()
    {
        $draft = auth()->user()->currentDraft();

        // ARCHITECTURE FIX: Eager load 'uom' to resolve the display bug in the draft view.
        $items = $draft
            ? $draft->items()->with(['item', 'uom'])->get()
            : collect();

        return view('customer.reservation.index', compact('draft', 'items'));
    }

    /**
     * Submit the reservation, moving it from Draft to Pending status. [3]
     */
    public function submit(Request $request)
    {
        $user = auth()->user();
        $draft = $user->currentDraft();

        // Validate draft is not empty [3]
        if (! $draft || $draft->items()->count() === 0) {
            return redirect()->back()->with('error', 'Your reservation is empty.');
        }

        // Generate Order Number and update status to Pending Review [3]
        $draft->update([
            'status' => 'pending',
            'order_number' => 'ORD-'.strtoupper(uniqid()),
            'created_at' => now(), // Reset timestamp to the actual submission time
        ]);

        // Manual Log for Submission Activity [4]
        activity('order')
            ->performedOn($draft)
            ->causedBy($user)
            ->log('Customer submitted reservation for review');

        return redirect()->route('dashboard')->with('success', 'Order submitted for CS review.');
    }

    /**
     * Fulfills Addendum 5.a: Normalizes UOM placeholders for DB integrity.
     */
    public function store(AddToCartRequest $request)
    {
        $user = auth()->user();
        $draft = $user->getOrCreateDraft();

        // ARCHITECTURE FIX: Direct UOM ID usage (normalization removed) [1]
        $uomId = $request->uom_id;

        $orderItem = $draft->items()
            ->where('item_id', $request->item_id)
            ->where('uom_id', $uomId)
            ->first();

        if ($orderItem) {
            $orderItem->increment('quantity', $request->quantity);
        } else {
            $item = Item::findOrFail($request->item_id);
            $draft->items()->create([
                'item_id' => $item->id,
                'uom_id' => $uomId,
                'snapshot_name' => $item->name,
                'quantity' => $request->quantity,
                'price_at_order' => 0, // Price Blind Policy [4.b]
            ]);
        }

        return redirect()->back()->with('success', 'Added to reservation.');
    }

    /**
     * Fulfills Request: Move a 'pending' order back to 'draft' status.
     */
    public function recall(\App\Models\Order $order)
    {
        // Security check: Ownership and Status
        if ($order->user_id !== auth()->id() || $order->status !== 'pending') {
            abort(403, 'Unauthorized recall attempt.');
        }

        $order->update([
            'status' => 'draft',
            'order_number' => null, // Reset order number until re-submitted
        ]);

        activity('order')
            ->performedOn($order)
            ->causedBy(auth()->user())
            ->log('Customer recalled pending order back to draft');

        return redirect()->route('reservation.index')->with('success', 'Order has been recalled to your draft for editing.');
    }

    /**
     * Update quantity or remove item from draft/pending order.
     * Fulfills Section 4.1 & 4.2
     */
    public function update(Request $request, OrderItem $orderItem)
    {
        // Security: Allow editing if status is draft OR pending
        if ($orderItem->order->user_id !== auth()->id() ||
            ! in_array($orderItem->order->status, ['draft', 'pending'])) {
            abort(403, 'This order is locked and cannot be edited.');
        }

        $request->validate(['quantity' => 'required|integer|min:1|max:999']);
        $orderItem->update(['quantity' => $request->quantity]);

        return redirect()->back()->with('success', 'Reservation updated.');
    }

    public function destroy(OrderItem $orderItem)
    {
        // Security: Allow removal if status is draft OR pending
        if ($orderItem->order->user_id !== auth()->id() ||
            ! in_array($orderItem->order->status, ['draft', 'pending'])) {
            abort(403, 'This order is locked.');
        }

        $orderItem->delete();

        return redirect()->back()->with('success', 'Item removed.');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Customer/OrderHistoryController.php ---
<?php

namespace App\Http\Controllers\Customer;

use App\Http\Controllers\Controller;

class OrderHistoryController extends Controller
{
    public function index()
    {
        // Fulfills Direct Ordering: Tied strictly to auth()->id() [1, 2]
        $orders = auth()->user()->orders()
            ->where('status', '!=', 'draft') // Drafts are managed in ReservationController
            ->latest()
            ->paginate(10);

        return view('customer.orders.index', compact('orders'));
    }

    public function show(\App\Models\Order $order)
    {
        // Security: Ensure owner [1]
        if ($order->user_id !== auth()->id()) {
            abort(403);
        }

        $order->load('items.item');

        return view('customer.orders.show', compact('order'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/Http/Controllers/Customer/ProductCatalogController.php ---
<?php

namespace App\Http\Controllers\Customer;

use App\Http\Controllers\Controller;
use App\Models\Category;
use App\Models\Item;
use Illuminate\Http\Request;

class ProductCatalogController extends Controller
{
    /**
     * Display the whitelisted products for the logged-in customer.
     * Fulfills Section 3.a Whitelist Logic.
     */
    public function index(Request $request)
    {
        $user = auth()->user();
        $catalogId = $user->getEffectiveCatalogId();
        $catalog = \App\Models\Catalog::find($catalogId);

        if (! $catalog || $catalog->status === 'deactive') {
            return view('customer.products.index', ['items' => collect(), 'availableCategories' => collect(), 'draftItems' => collect()]);
        }

        $query = Item::where('status', 'active')
            ->whereHas('catalogs', fn ($q) => $q->where('catalogs.id', $catalogId));

        if ($request->filled('search')) {
            $query->where(fn ($q) => $q->where('name', 'like', "%{$request->search}%")->orWhere('sku', 'like', "%{$request->search}%"));
        }

        if ($request->filled('category')) {
            $query->whereHas('categories', fn ($q) => $q->where('categories.id', $request->category));
        }

        $items = $query->with(['categories', 'activeUoms'])->latest()->paginate(12)->withQueryString();
        $availableCategories = Category::where('status', 'active')
            ->whereHas('items', fn ($q) => $q->where('items.status', 'active')->whereHas('catalogs', fn ($c) => $c->where('catalogs.id', $catalogId)))
            ->get();

        // Fulfills Requirement: Pass draft items to view for "Mark Down" logic
        $draftItems = $user->currentDraft()?->items ?? collect();

        return view('customer.products.index', compact('items', 'availableCategories', 'draftItems'));
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/View/Components/GuestLayout.php ---
<?php

namespace App\View\Components;

use Illuminate\View\Component;
use Illuminate\View\View;

class GuestLayout extends Component
{
    /**
     * Get the view / contents that represents the component.
     */
    public function render(): View
    {
        return view('layouts.guest');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/app/View/Components/AppLayout.php ---
<?php

namespace App\View\Components;

use Illuminate\View\Component;
use Illuminate\View\View;

class AppLayout extends Component
{
    /**
     * Get the view / contents that represents the component.
     */
    public function render(): View
    {
        return view('layouts.app');
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/auth.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Authentication Defaults
    |--------------------------------------------------------------------------
    |
    | This option defines the default authentication "guard" and password
    | reset "broker" for your application. You may change these values
    | as required, but they're a perfect start for most applications.
    |
    */

    'defaults' => [
        'guard' => env('AUTH_GUARD', 'web'),
        'passwords' => env('AUTH_PASSWORD_BROKER', 'users'),
    ],

    /*
    |--------------------------------------------------------------------------
    | Authentication Guards
    |--------------------------------------------------------------------------
    |
    | Next, you may define every authentication guard for your application.
    | Of course, a great default configuration has been defined for you
    | which utilizes session storage plus the Eloquent user provider.
    |
    | All authentication guards have a user provider, which defines how the
    | users are actually retrieved out of your database or other storage
    | system used by the application. Typically, Eloquent is utilized.
    |
    | Supported: "session"
    |
    */

    'guards' => [
        'web' => [
            'driver' => 'session',
            'provider' => 'users',
        ],
    ],

    /*
    |--------------------------------------------------------------------------
    | User Providers
    |--------------------------------------------------------------------------
    |
    | All authentication guards have a user provider, which defines how the
    | users are actually retrieved out of your database or other storage
    | system used by the application. Typically, Eloquent is utilized.
    |
    | If you have multiple user tables or models you may configure multiple
    | providers to represent the model / table. These providers may then
    | be assigned to any extra authentication guards you have defined.
    |
    | Supported: "database", "eloquent"
    |
    */

    'providers' => [
        'users' => [
            'driver' => 'eloquent',
            'model' => env('AUTH_MODEL', App\Models\User::class),
        ],

        // 'users' => [
        //     'driver' => 'database',
        //     'table' => 'users',
        // ],
    ],

    /*
    |--------------------------------------------------------------------------
    | Resetting Passwords
    |--------------------------------------------------------------------------
    |
    | These configuration options specify the behavior of Laravel's password
    | reset functionality, including the table utilized for token storage
    | and the user provider that is invoked to actually retrieve users.
    |
    | The expiry time is the number of minutes that each reset token will be
    | considered valid. This security feature keeps tokens short-lived so
    | they have less time to be guessed. You may change this as needed.
    |
    | The throttle setting is the number of seconds a user must wait before
    | generating more password reset tokens. This prevents the user from
    | quickly generating a very large amount of password reset tokens.
    |
    */

    'passwords' => [
        'users' => [
            'provider' => 'users',
            'table' => env('AUTH_PASSWORD_RESET_TOKEN_TABLE', 'password_reset_tokens'),
            'expire' => 60,
            'throttle' => 60,
        ],
    ],

    /*
    |--------------------------------------------------------------------------
    | Password Confirmation Timeout
    |--------------------------------------------------------------------------
    |
    | Here you may define the number of seconds before a password confirmation
    | window expires and users are asked to re-enter their password via the
    | confirmation screen. By default, the timeout lasts for three hours.
    |
    */

    'password_timeout' => env('AUTH_PASSWORD_TIMEOUT', 10800),

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/app.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Application Name
    |--------------------------------------------------------------------------
    |
    | This value is the name of your application, which will be used when the
    | framework needs to place the application's name in a notification or
    | other UI elements where an application name needs to be displayed.
    |
    */

    'name' => env('APP_NAME', 'Laravel'),

    /*
    |--------------------------------------------------------------------------
    | Application Environment
    |--------------------------------------------------------------------------
    |
    | This value determines the "environment" your application is currently
    | running in. This may determine how you prefer to configure various
    | services the application utilizes. Set this in your ".env" file.
    |
    */

    'env' => env('APP_ENV', 'production'),

    /*
    |--------------------------------------------------------------------------
    | Application Debug Mode
    |--------------------------------------------------------------------------
    |
    | When your application is in debug mode, detailed error messages with
    | stack traces will be shown on every error that occurs within your
    | application. If disabled, a simple generic error page is shown.
    |
    */

    'debug' => (bool) env('APP_DEBUG', false),

    /*
    |--------------------------------------------------------------------------
    | Application URL
    |--------------------------------------------------------------------------
    |
    | This URL is used by the console to properly generate URLs when using
    | the Artisan command line tool. You should set this to the root of
    | the application so that it's available within Artisan commands.
    |
    */

    'url' => env('APP_URL', 'http://localhost'),

    /*
    |--------------------------------------------------------------------------
    | Application Timezone
    |--------------------------------------------------------------------------
    |
    | Here you may specify the default timezone for your application, which
    | will be used by the PHP date and date-time functions. The timezone
    | is set to "UTC" by default as it is suitable for most use cases.
    |
    */

    'timezone' => 'UTC',

    /*
    |--------------------------------------------------------------------------
    | Application Locale Configuration
    |--------------------------------------------------------------------------
    |
    | The application locale determines the default locale that will be used
    | by Laravel's translation / localization methods. This option can be
    | set to any locale for which you plan to have translation strings.
    |
    */

    'locale' => env('APP_LOCALE', 'en'),

    'fallback_locale' => env('APP_FALLBACK_LOCALE', 'en'),

    'faker_locale' => env('APP_FAKER_LOCALE', 'en_US'),

    /*
    |--------------------------------------------------------------------------
    | Encryption Key
    |--------------------------------------------------------------------------
    |
    | This key is utilized by Laravel's encryption services and should be set
    | to a random, 32 character string to ensure that all encrypted values
    | are secure. You should do this prior to deploying the application.
    |
    */

    'cipher' => 'AES-256-CBC',

    'key' => env('APP_KEY'),

    'previous_keys' => [
        ...array_filter(
            explode(',', (string) env('APP_PREVIOUS_KEYS', ''))
        ),
    ],

    /*
    |--------------------------------------------------------------------------
    | Maintenance Mode Driver
    |--------------------------------------------------------------------------
    |
    | These configuration options determine the driver used to determine and
    | manage Laravel's "maintenance mode" status. The "cache" driver will
    | allow maintenance mode to be controlled across multiple machines.
    |
    | Supported drivers: "file", "cache"
    |
    */

    'maintenance' => [
        'driver' => env('APP_MAINTENANCE_DRIVER', 'file'),
        'store' => env('APP_MAINTENANCE_STORE', 'database'),
    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/mail.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Default Mailer
    |--------------------------------------------------------------------------
    |
    | This option controls the default mailer that is used to send all email
    | messages unless another mailer is explicitly specified when sending
    | the message. All additional mailers can be configured within the
    | "mailers" array. Examples of each type of mailer are provided.
    |
    */

    'default' => env('MAIL_MAILER', 'log'),

    /*
    |--------------------------------------------------------------------------
    | Mailer Configurations
    |--------------------------------------------------------------------------
    |
    | Here you may configure all of the mailers used by your application plus
    | their respective settings. Several examples have been configured for
    | you and you are free to add your own as your application requires.
    |
    | Laravel supports a variety of mail "transport" drivers that can be used
    | when delivering an email. You may specify which one you're using for
    | your mailers below. You may also add additional mailers if needed.
    |
    | Supported: "smtp", "sendmail", "mailgun", "ses", "ses-v2",
    |            "postmark", "resend", "log", "array",
    |            "failover", "roundrobin"
    |
    */

    'mailers' => [

        'smtp' => [
            'transport' => 'smtp',
            'scheme' => env('MAIL_SCHEME'),
            'url' => env('MAIL_URL'),
            'host' => env('MAIL_HOST', '127.0.0.1'),
            'port' => env('MAIL_PORT', 2525),
            'username' => env('MAIL_USERNAME'),
            'password' => env('MAIL_PASSWORD'),
            'timeout' => null,
            'local_domain' => env('MAIL_EHLO_DOMAIN', parse_url((string) env('APP_URL', 'http://localhost'), PHP_URL_HOST)),
        ],

        'ses' => [
            'transport' => 'ses',
        ],

        'postmark' => [
            'transport' => 'postmark',
            // 'message_stream_id' => env('POSTMARK_MESSAGE_STREAM_ID'),
            // 'client' => [
            //     'timeout' => 5,
            // ],
        ],

        'resend' => [
            'transport' => 'resend',
        ],

        'sendmail' => [
            'transport' => 'sendmail',
            'path' => env('MAIL_SENDMAIL_PATH', '/usr/sbin/sendmail -bs -i'),
        ],

        'log' => [
            'transport' => 'log',
            'channel' => env('MAIL_LOG_CHANNEL'),
        ],

        'array' => [
            'transport' => 'array',
        ],

        'failover' => [
            'transport' => 'failover',
            'mailers' => [
                'smtp',
                'log',
            ],
            'retry_after' => 60,
        ],

        'roundrobin' => [
            'transport' => 'roundrobin',
            'mailers' => [
                'ses',
                'postmark',
            ],
            'retry_after' => 60,
        ],

    ],

    /*
    |--------------------------------------------------------------------------
    | Global "From" Address
    |--------------------------------------------------------------------------
    |
    | You may wish for all emails sent by your application to be sent from
    | the same address. Here you may specify a name and address that is
    | used globally for all emails that are sent by your application.
    |
    */

    'from' => [
        'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'),
        'name' => env('MAIL_FROM_NAME', 'Example'),
    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/services.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Third Party Services
    |--------------------------------------------------------------------------
    |
    | This file is for storing the credentials for third party services such
    | as Mailgun, Postmark, AWS and more. This file provides the de facto
    | location for this type of information, allowing packages to have
    | a conventional file to locate the various service credentials.
    |
    */

    'postmark' => [
        'key' => env('POSTMARK_API_KEY'),
    ],

    'resend' => [
        'key' => env('RESEND_API_KEY'),
    ],

    'ses' => [
        'key' => env('AWS_ACCESS_KEY_ID'),
        'secret' => env('AWS_SECRET_ACCESS_KEY'),
        'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
    ],

    'slack' => [
        'notifications' => [
            'bot_user_oauth_token' => env('SLACK_BOT_USER_OAUTH_TOKEN'),
            'channel' => env('SLACK_BOT_USER_DEFAULT_CHANNEL'),
        ],
    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/database.php ---
<?php

use Illuminate\Support\Str;

return [

    /*
    |--------------------------------------------------------------------------
    | Default Database Connection Name
    |--------------------------------------------------------------------------
    |
    | Here you may specify which of the database connections below you wish
    | to use as your default connection for database operations. This is
    | the connection which will be utilized unless another connection
    | is explicitly specified when you execute a query / statement.
    |
    */

    'default' => env('DB_CONNECTION', 'sqlite'),

    /*
    |--------------------------------------------------------------------------
    | Database Connections
    |--------------------------------------------------------------------------
    |
    | Below are all of the database connections defined for your application.
    | An example configuration is provided for each database system which
    | is supported by Laravel. You're free to add / remove connections.
    |
    */

    'connections' => [

        'sqlite' => [
            'driver' => 'sqlite',
            'url' => env('DB_URL'),
            'database' => env('DB_DATABASE', database_path('database.sqlite')),
            'prefix' => '',
            'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true),
            'busy_timeout' => null,
            'journal_mode' => null,
            'synchronous' => null,
            'transaction_mode' => 'DEFERRED',
        ],

        'mysql' => [
            'driver' => 'mysql',
            'url' => env('DB_URL'),
            'host' => env('DB_HOST', '127.0.0.1'),
            'port' => env('DB_PORT', '3306'),
            'database' => env('DB_DATABASE', 'laravel'),
            'username' => env('DB_USERNAME', 'root'),
            'password' => env('DB_PASSWORD', ''),
            'unix_socket' => env('DB_SOCKET', ''),
            'charset' => env('DB_CHARSET', 'utf8mb4'),
            'collation' => env('DB_COLLATION', 'utf8mb4_unicode_ci'),
            'prefix' => '',
            'prefix_indexes' => true,
            'strict' => true,
            'engine' => null,
            'options' => extension_loaded('pdo_mysql') ? array_filter([
                (PHP_VERSION_ID >= 80500 ? \Pdo\Mysql::ATTR_SSL_CA : \PDO::MYSQL_ATTR_SSL_CA) => env('MYSQL_ATTR_SSL_CA'),
            ]) : [],
        ],

        'mariadb' => [
            'driver' => 'mariadb',
            'url' => env('DB_URL'),
            'host' => env('DB_HOST', '127.0.0.1'),
            'port' => env('DB_PORT', '3306'),
            'database' => env('DB_DATABASE', 'laravel'),
            'username' => env('DB_USERNAME', 'root'),
            'password' => env('DB_PASSWORD', ''),
            'unix_socket' => env('DB_SOCKET', ''),
            'charset' => env('DB_CHARSET', 'utf8mb4'),
            'collation' => env('DB_COLLATION', 'utf8mb4_unicode_ci'),
            'prefix' => '',
            'prefix_indexes' => true,
            'strict' => true,
            'engine' => null,
            'options' => extension_loaded('pdo_mysql') ? array_filter([
                (PHP_VERSION_ID >= 80500 ? \Pdo\Mysql::ATTR_SSL_CA : \PDO::MYSQL_ATTR_SSL_CA) => env('MYSQL_ATTR_SSL_CA'),
            ]) : [],
        ],

        'pgsql' => [
            'driver' => 'pgsql',
            'url' => env('DB_URL'),
            'host' => env('DB_HOST', '127.0.0.1'),
            'port' => env('DB_PORT', '5432'),
            'database' => env('DB_DATABASE', 'laravel'),
            'username' => env('DB_USERNAME', 'root'),
            'password' => env('DB_PASSWORD', ''),
            'charset' => env('DB_CHARSET', 'utf8'),
            'prefix' => '',
            'prefix_indexes' => true,
            'search_path' => 'public',
            'sslmode' => 'prefer',
        ],

        'sqlsrv' => [
            'driver' => 'sqlsrv',
            'url' => env('DB_URL'),
            'host' => env('DB_HOST', 'localhost'),
            'port' => env('DB_PORT', '1433'),
            'database' => env('DB_DATABASE', 'laravel'),
            'username' => env('DB_USERNAME', 'root'),
            'password' => env('DB_PASSWORD', ''),
            'charset' => env('DB_CHARSET', 'utf8'),
            'prefix' => '',
            'prefix_indexes' => true,
            // 'encrypt' => env('DB_ENCRYPT', 'yes'),
            // 'trust_server_certificate' => env('DB_TRUST_SERVER_CERTIFICATE', 'false'),
        ],

    ],

    /*
    |--------------------------------------------------------------------------
    | Migration Repository Table
    |--------------------------------------------------------------------------
    |
    | This table keeps track of all the migrations that have already run for
    | your application. Using this information, we can determine which of
    | the migrations on disk haven't actually been run on the database.
    |
    */

    'migrations' => [
        'table' => 'migrations',
        'update_date_on_publish' => true,
    ],

    /*
    |--------------------------------------------------------------------------
    | Redis Databases
    |--------------------------------------------------------------------------
    |
    | Redis is an open source, fast, and advanced key-value store that also
    | provides a richer body of commands than a typical key-value system
    | such as Memcached. You may define your connection settings here.
    |
    */

    'redis' => [

        'client' => env('REDIS_CLIENT', 'phpredis'),

        'options' => [
            'cluster' => env('REDIS_CLUSTER', 'redis'),
            'prefix' => env('REDIS_PREFIX', Str::slug((string) env('APP_NAME', 'laravel')).'-database-'),
            'persistent' => env('REDIS_PERSISTENT', false),
        ],

        'default' => [
            'url' => env('REDIS_URL'),
            'host' => env('REDIS_HOST', '127.0.0.1'),
            'username' => env('REDIS_USERNAME'),
            'password' => env('REDIS_PASSWORD'),
            'port' => env('REDIS_PORT', '6379'),
            'database' => env('REDIS_DB', '0'),
            'max_retries' => env('REDIS_MAX_RETRIES', 3),
            'backoff_algorithm' => env('REDIS_BACKOFF_ALGORITHM', 'decorrelated_jitter'),
            'backoff_base' => env('REDIS_BACKOFF_BASE', 100),
            'backoff_cap' => env('REDIS_BACKOFF_CAP', 1000),
        ],

        'cache' => [
            'url' => env('REDIS_URL'),
            'host' => env('REDIS_HOST', '127.0.0.1'),
            'username' => env('REDIS_USERNAME'),
            'password' => env('REDIS_PASSWORD'),
            'port' => env('REDIS_PORT', '6379'),
            'database' => env('REDIS_CACHE_DB', '1'),
            'max_retries' => env('REDIS_MAX_RETRIES', 3),
            'backoff_algorithm' => env('REDIS_BACKOFF_ALGORITHM', 'decorrelated_jitter'),
            'backoff_base' => env('REDIS_BACKOFF_BASE', 100),
            'backoff_cap' => env('REDIS_BACKOFF_CAP', 1000),
        ],

    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/cache.php ---
<?php

use Illuminate\Support\Str;

return [

    /*
    |--------------------------------------------------------------------------
    | Default Cache Store
    |--------------------------------------------------------------------------
    |
    | This option controls the default cache store that will be used by the
    | framework. This connection is utilized if another isn't explicitly
    | specified when running a cache operation inside the application.
    |
    */

    'default' => env('CACHE_STORE', 'database'),

    /*
    |--------------------------------------------------------------------------
    | Cache Stores
    |--------------------------------------------------------------------------
    |
    | Here you may define all of the cache "stores" for your application as
    | well as their drivers. You may even define multiple stores for the
    | same cache driver to group types of items stored in your caches.
    |
    | Supported drivers: "array", "database", "file", "memcached",
    |                    "redis", "dynamodb", "octane",
    |                    "failover", "null"
    |
    */

    'stores' => [

        'array' => [
            'driver' => 'array',
            'serialize' => false,
        ],

        'database' => [
            'driver' => 'database',
            'connection' => env('DB_CACHE_CONNECTION'),
            'table' => env('DB_CACHE_TABLE', 'cache'),
            'lock_connection' => env('DB_CACHE_LOCK_CONNECTION'),
            'lock_table' => env('DB_CACHE_LOCK_TABLE'),
        ],

        'file' => [
            'driver' => 'file',
            'path' => storage_path('framework/cache/data'),
            'lock_path' => storage_path('framework/cache/data'),
        ],

        'memcached' => [
            'driver' => 'memcached',
            'persistent_id' => env('MEMCACHED_PERSISTENT_ID'),
            'sasl' => [
                env('MEMCACHED_USERNAME'),
                env('MEMCACHED_PASSWORD'),
            ],
            'options' => [
                // Memcached::OPT_CONNECT_TIMEOUT => 2000,
            ],
            'servers' => [
                [
                    'host' => env('MEMCACHED_HOST', '127.0.0.1'),
                    'port' => env('MEMCACHED_PORT', 11211),
                    'weight' => 100,
                ],
            ],
        ],

        'redis' => [
            'driver' => 'redis',
            'connection' => env('REDIS_CACHE_CONNECTION', 'cache'),
            'lock_connection' => env('REDIS_CACHE_LOCK_CONNECTION', 'default'),
        ],

        'dynamodb' => [
            'driver' => 'dynamodb',
            'key' => env('AWS_ACCESS_KEY_ID'),
            'secret' => env('AWS_SECRET_ACCESS_KEY'),
            'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
            'table' => env('DYNAMODB_CACHE_TABLE', 'cache'),
            'endpoint' => env('DYNAMODB_ENDPOINT'),
        ],

        'octane' => [
            'driver' => 'octane',
        ],

        'failover' => [
            'driver' => 'failover',
            'stores' => [
                'database',
                'array',
            ],
        ],

    ],

    /*
    |--------------------------------------------------------------------------
    | Cache Key Prefix
    |--------------------------------------------------------------------------
    |
    | When utilizing the APC, database, memcached, Redis, and DynamoDB cache
    | stores, there might be other applications using the same cache. For
    | that reason, you may prefix every cache key to avoid collisions.
    |
    */

    'prefix' => env('CACHE_PREFIX', Str::slug((string) env('APP_NAME', 'laravel')).'-cache-'),

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/session.php ---
<?php

use Illuminate\Support\Str;

return [

    /*
    |--------------------------------------------------------------------------
    | Default Session Driver
    |--------------------------------------------------------------------------
    |
    | This option determines the default session driver that is utilized for
    | incoming requests. Laravel supports a variety of storage options to
    | persist session data. Database storage is a great default choice.
    |
    | Supported: "file", "cookie", "database", "memcached",
    |            "redis", "dynamodb", "array"
    |
    */

    'driver' => env('SESSION_DRIVER', 'database'),

    /*
    |--------------------------------------------------------------------------
    | Session Lifetime
    |--------------------------------------------------------------------------
    |
    | Here you may specify the number of minutes that you wish the session
    | to be allowed to remain idle before it expires. If you want them
    | to expire immediately when the browser is closed then you may
    | indicate that via the expire_on_close configuration option.
    |
    */

    'lifetime' => (int) env('SESSION_LIFETIME', 120),

    'expire_on_close' => env('SESSION_EXPIRE_ON_CLOSE', false),

    /*
    |--------------------------------------------------------------------------
    | Session Encryption
    |--------------------------------------------------------------------------
    |
    | This option allows you to easily specify that all of your session data
    | should be encrypted before it's stored. All encryption is performed
    | automatically by Laravel and you may use the session like normal.
    |
    */

    'encrypt' => env('SESSION_ENCRYPT', false),

    /*
    |--------------------------------------------------------------------------
    | Session File Location
    |--------------------------------------------------------------------------
    |
    | When utilizing the "file" session driver, the session files are placed
    | on disk. The default storage location is defined here; however, you
    | are free to provide another location where they should be stored.
    |
    */

    'files' => storage_path('framework/sessions'),

    /*
    |--------------------------------------------------------------------------
    | Session Database Connection
    |--------------------------------------------------------------------------
    |
    | When using the "database" or "redis" session drivers, you may specify a
    | connection that should be used to manage these sessions. This should
    | correspond to a connection in your database configuration options.
    |
    */

    'connection' => env('SESSION_CONNECTION'),

    /*
    |--------------------------------------------------------------------------
    | Session Database Table
    |--------------------------------------------------------------------------
    |
    | When using the "database" session driver, you may specify the table to
    | be used to store sessions. Of course, a sensible default is defined
    | for you; however, you're welcome to change this to another table.
    |
    */

    'table' => env('SESSION_TABLE', 'sessions'),

    /*
    |--------------------------------------------------------------------------
    | Session Cache Store
    |--------------------------------------------------------------------------
    |
    | When using one of the framework's cache driven session backends, you may
    | define the cache store which should be used to store the session data
    | between requests. This must match one of your defined cache stores.
    |
    | Affects: "dynamodb", "memcached", "redis"
    |
    */

    'store' => env('SESSION_STORE'),

    /*
    |--------------------------------------------------------------------------
    | Session Sweeping Lottery
    |--------------------------------------------------------------------------
    |
    | Some session drivers must manually sweep their storage location to get
    | rid of old sessions from storage. Here are the chances that it will
    | happen on a given request. By default, the odds are 2 out of 100.
    |
    */

    'lottery' => [2, 100],

    /*
    |--------------------------------------------------------------------------
    | Session Cookie Name
    |--------------------------------------------------------------------------
    |
    | Here you may change the name of the session cookie that is created by
    | the framework. Typically, you should not need to change this value
    | since doing so does not grant a meaningful security improvement.
    |
    */

    'cookie' => env(
        'SESSION_COOKIE',
        Str::slug((string) env('APP_NAME', 'laravel')).'-session'
    ),

    /*
    |--------------------------------------------------------------------------
    | Session Cookie Path
    |--------------------------------------------------------------------------
    |
    | The session cookie path determines the path for which the cookie will
    | be regarded as available. Typically, this will be the root path of
    | your application, but you're free to change this when necessary.
    |
    */

    'path' => env('SESSION_PATH', '/'),

    /*
    |--------------------------------------------------------------------------
    | Session Cookie Domain
    |--------------------------------------------------------------------------
    |
    | This value determines the domain and subdomains the session cookie is
    | available to. By default, the cookie will be available to the root
    | domain without subdomains. Typically, this shouldn't be changed.
    |
    */

    'domain' => env('SESSION_DOMAIN'),

    /*
    |--------------------------------------------------------------------------
    | HTTPS Only Cookies
    |--------------------------------------------------------------------------
    |
    | By setting this option to true, session cookies will only be sent back
    | to the server if the browser has a HTTPS connection. This will keep
    | the cookie from being sent to you when it can't be done securely.
    |
    */

    'secure' => env('SESSION_SECURE_COOKIE'),

    /*
    |--------------------------------------------------------------------------
    | HTTP Access Only
    |--------------------------------------------------------------------------
    |
    | Setting this value to true will prevent JavaScript from accessing the
    | value of the cookie and the cookie will only be accessible through
    | the HTTP protocol. It's unlikely you should disable this option.
    |
    */

    'http_only' => env('SESSION_HTTP_ONLY', true),

    /*
    |--------------------------------------------------------------------------
    | Same-Site Cookies
    |--------------------------------------------------------------------------
    |
    | This option determines how your cookies behave when cross-site requests
    | take place, and can be used to mitigate CSRF attacks. By default, we
    | will set this value to "lax" to permit secure cross-site requests.
    |
    | See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie#samesitesamesite-value
    |
    | Supported: "lax", "strict", "none", null
    |
    */

    'same_site' => env('SESSION_SAME_SITE', 'lax'),

    /*
    |--------------------------------------------------------------------------
    | Partitioned Cookies
    |--------------------------------------------------------------------------
    |
    | Setting this value to true will tie the cookie to the top-level site for
    | a cross-site context. Partitioned cookies are accepted by the browser
    | when flagged "secure" and the Same-Site attribute is set to "none".
    |
    */

    'partitioned' => env('SESSION_PARTITIONED_COOKIE', false),

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/queue.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Default Queue Connection Name
    |--------------------------------------------------------------------------
    |
    | Laravel's queue supports a variety of backends via a single, unified
    | API, giving you convenient access to each backend using identical
    | syntax for each. The default queue connection is defined below.
    |
    */

    'default' => env('QUEUE_CONNECTION', 'database'),

    /*
    |--------------------------------------------------------------------------
    | Queue Connections
    |--------------------------------------------------------------------------
    |
    | Here you may configure the connection options for every queue backend
    | used by your application. An example configuration is provided for
    | each backend supported by Laravel. You're also free to add more.
    |
    | Drivers: "sync", "database", "beanstalkd", "sqs", "redis",
    |          "deferred", "background", "failover", "null"
    |
    */

    'connections' => [

        'sync' => [
            'driver' => 'sync',
        ],

        'database' => [
            'driver' => 'database',
            'connection' => env('DB_QUEUE_CONNECTION'),
            'table' => env('DB_QUEUE_TABLE', 'jobs'),
            'queue' => env('DB_QUEUE', 'default'),
            'retry_after' => (int) env('DB_QUEUE_RETRY_AFTER', 90),
            'after_commit' => false,
        ],

        'beanstalkd' => [
            'driver' => 'beanstalkd',
            'host' => env('BEANSTALKD_QUEUE_HOST', 'localhost'),
            'queue' => env('BEANSTALKD_QUEUE', 'default'),
            'retry_after' => (int) env('BEANSTALKD_QUEUE_RETRY_AFTER', 90),
            'block_for' => 0,
            'after_commit' => false,
        ],

        'sqs' => [
            'driver' => 'sqs',
            'key' => env('AWS_ACCESS_KEY_ID'),
            'secret' => env('AWS_SECRET_ACCESS_KEY'),
            'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
            'queue' => env('SQS_QUEUE', 'default'),
            'suffix' => env('SQS_SUFFIX'),
            'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
            'after_commit' => false,
        ],

        'redis' => [
            'driver' => 'redis',
            'connection' => env('REDIS_QUEUE_CONNECTION', 'default'),
            'queue' => env('REDIS_QUEUE', 'default'),
            'retry_after' => (int) env('REDIS_QUEUE_RETRY_AFTER', 90),
            'block_for' => null,
            'after_commit' => false,
        ],

        'deferred' => [
            'driver' => 'deferred',
        ],

        'background' => [
            'driver' => 'background',
        ],

        'failover' => [
            'driver' => 'failover',
            'connections' => [
                'database',
                'deferred',
            ],
        ],

    ],

    /*
    |--------------------------------------------------------------------------
    | Job Batching
    |--------------------------------------------------------------------------
    |
    | The following options configure the database and table that store job
    | batching information. These options can be updated to any database
    | connection and table which has been defined by your application.
    |
    */

    'batching' => [
        'database' => env('DB_CONNECTION', 'sqlite'),
        'table' => 'job_batches',
    ],

    /*
    |--------------------------------------------------------------------------
    | Failed Queue Jobs
    |--------------------------------------------------------------------------
    |
    | These options configure the behavior of failed queue job logging so you
    | can control how and where failed jobs are stored. Laravel ships with
    | support for storing failed jobs in a simple file or in a database.
    |
    | Supported drivers: "database-uuids", "dynamodb", "file", "null"
    |
    */

    'failed' => [
        'driver' => env('QUEUE_FAILED_DRIVER', 'database-uuids'),
        'database' => env('DB_CONNECTION', 'sqlite'),
        'table' => 'failed_jobs',
    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/logging.php ---
<?php

use Monolog\Handler\NullHandler;
use Monolog\Handler\StreamHandler;
use Monolog\Handler\SyslogUdpHandler;
use Monolog\Processor\PsrLogMessageProcessor;

return [

    /*
    |--------------------------------------------------------------------------
    | Default Log Channel
    |--------------------------------------------------------------------------
    |
    | This option defines the default log channel that is utilized to write
    | messages to your logs. The value provided here should match one of
    | the channels present in the list of "channels" configured below.
    |
    */

    'default' => env('LOG_CHANNEL', 'stack'),

    /*
    |--------------------------------------------------------------------------
    | Deprecations Log Channel
    |--------------------------------------------------------------------------
    |
    | This option controls the log channel that should be used to log warnings
    | regarding deprecated PHP and library features. This allows you to get
    | your application ready for upcoming major versions of dependencies.
    |
    */

    'deprecations' => [
        'channel' => env('LOG_DEPRECATIONS_CHANNEL', 'null'),
        'trace' => env('LOG_DEPRECATIONS_TRACE', false),
    ],

    /*
    |--------------------------------------------------------------------------
    | Log Channels
    |--------------------------------------------------------------------------
    |
    | Here you may configure the log channels for your application. Laravel
    | utilizes the Monolog PHP logging library, which includes a variety
    | of powerful log handlers and formatters that you're free to use.
    |
    | Available drivers: "single", "daily", "slack", "syslog",
    |                    "errorlog", "monolog", "custom", "stack"
    |
    */

    'channels' => [

        'stack' => [
            'driver' => 'stack',
            'channels' => explode(',', (string) env('LOG_STACK', 'single')),
            'ignore_exceptions' => false,
        ],

        'single' => [
            'driver' => 'single',
            'path' => storage_path('logs/laravel.log'),
            'level' => env('LOG_LEVEL', 'debug'),
            'replace_placeholders' => true,
        ],

        'daily' => [
            'driver' => 'daily',
            'path' => storage_path('logs/laravel.log'),
            'level' => env('LOG_LEVEL', 'debug'),
            'days' => env('LOG_DAILY_DAYS', 14),
            'replace_placeholders' => true,
        ],

        'slack' => [
            'driver' => 'slack',
            'url' => env('LOG_SLACK_WEBHOOK_URL'),
            'username' => env('LOG_SLACK_USERNAME', 'Laravel Log'),
            'emoji' => env('LOG_SLACK_EMOJI', ':boom:'),
            'level' => env('LOG_LEVEL', 'critical'),
            'replace_placeholders' => true,
        ],

        'papertrail' => [
            'driver' => 'monolog',
            'level' => env('LOG_LEVEL', 'debug'),
            'handler' => env('LOG_PAPERTRAIL_HANDLER', SyslogUdpHandler::class),
            'handler_with' => [
                'host' => env('PAPERTRAIL_URL'),
                'port' => env('PAPERTRAIL_PORT'),
                'connectionString' => 'tls://'.env('PAPERTRAIL_URL').':'.env('PAPERTRAIL_PORT'),
            ],
            'processors' => [PsrLogMessageProcessor::class],
        ],

        'stderr' => [
            'driver' => 'monolog',
            'level' => env('LOG_LEVEL', 'debug'),
            'handler' => StreamHandler::class,
            'handler_with' => [
                'stream' => 'php://stderr',
            ],
            'formatter' => env('LOG_STDERR_FORMATTER'),
            'processors' => [PsrLogMessageProcessor::class],
        ],

        'syslog' => [
            'driver' => 'syslog',
            'level' => env('LOG_LEVEL', 'debug'),
            'facility' => env('LOG_SYSLOG_FACILITY', LOG_USER),
            'replace_placeholders' => true,
        ],

        'errorlog' => [
            'driver' => 'errorlog',
            'level' => env('LOG_LEVEL', 'debug'),
            'replace_placeholders' => true,
        ],

        'null' => [
            'driver' => 'monolog',
            'handler' => NullHandler::class,
        ],

        'emergency' => [
            'path' => storage_path('logs/laravel.log'),
        ],

    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/permission.php ---
<?php

return [

    'models' => [

        /*
         * When using the "HasPermissions" trait from this package, we need to know which
         * Eloquent model should be used to retrieve your permissions. Of course, it
         * is often just the "Permission" model but you may use whatever you like.
         *
         * The model you want to use as a Permission model needs to implement the
         * `Spatie\Permission\Contracts\Permission` contract.
         */

        'permission' => Spatie\Permission\Models\Permission::class,

        /*
         * When using the "HasRoles" trait from this package, we need to know which
         * Eloquent model should be used to retrieve your roles. Of course, it
         * is often just the "Role" model but you may use whatever you like.
         *
         * The model you want to use as a Role model needs to implement the
         * `Spatie\Permission\Contracts\Role` contract.
         */

        'role' => Spatie\Permission\Models\Role::class,

    ],

    'table_names' => [

        /*
         * When using the "HasRoles" trait from this package, we need to know which
         * table should be used to retrieve your roles. We have chosen a basic
         * default value but you may easily change it to any table you like.
         */

        'roles' => 'roles',

        /*
         * When using the "HasPermissions" trait from this package, we need to know which
         * table should be used to retrieve your permissions. We have chosen a basic
         * default value but you may easily change it to any table you like.
         */

        'permissions' => 'permissions',

        /*
         * When using the "HasPermissions" trait from this package, we need to know which
         * table should be used to retrieve your models permissions. We have chosen a
         * basic default value but you may easily change it to any table you like.
         */

        'model_has_permissions' => 'model_has_permissions',

        /*
         * When using the "HasRoles" trait from this package, we need to know which
         * table should be used to retrieve your models roles. We have chosen a
         * basic default value but you may easily change it to any table you like.
         */

        'model_has_roles' => 'model_has_roles',

        /*
         * When using the "HasRoles" trait from this package, we need to know which
         * table should be used to retrieve your roles permissions. We have chosen a
         * basic default value but you may easily change it to any table you like.
         */

        'role_has_permissions' => 'role_has_permissions',
    ],

    'column_names' => [
        /*
         * Change this if you want to name the related pivots other than defaults
         */
        'role_pivot_key' => null, // default 'role_id',
        'permission_pivot_key' => null, // default 'permission_id',

        /*
         * Change this if you want to name the related model primary key other than
         * `model_id`.
         *
         * For example, this would be nice if your primary keys are all UUIDs. In
         * that case, name this `model_uuid`.
         */

        'model_morph_key' => 'model_id',

        /*
         * Change this if you want to use the teams feature and your related model's
         * foreign key is other than `team_id`.
         */

        'team_foreign_key' => 'team_id',
    ],

    /*
     * When set to true, the method for checking permissions will be registered on the gate.
     * Set this to false if you want to implement custom logic for checking permissions.
     */

    'register_permission_check_method' => true,

    /*
     * When set to true, Laravel\Octane\Events\OperationTerminated event listener will be registered
     * this will refresh permissions on every TickTerminated, TaskTerminated and RequestTerminated
     * NOTE: This should not be needed in most cases, but an Octane/Vapor combination benefited from it.
     */
    'register_octane_reset_listener' => false,

    /*
     * Events will fire when a role or permission is assigned/unassigned:
     * \Spatie\Permission\Events\RoleAttached
     * \Spatie\Permission\Events\RoleDetached
     * \Spatie\Permission\Events\PermissionAttached
     * \Spatie\Permission\Events\PermissionDetached
     *
     * To enable, set to true, and then create listeners to watch these events.
     */
    'events_enabled' => false,

    /*
     * Teams Feature.
     * When set to true the package implements teams using the 'team_foreign_key'.
     * If you want the migrations to register the 'team_foreign_key', you must
     * set this to true before doing the migration.
     * If you already did the migration then you must make a new migration to also
     * add 'team_foreign_key' to 'roles', 'model_has_roles', and 'model_has_permissions'
     * (view the latest version of this package's migration file)
     */

    'teams' => false,

    /*
     * The class to use to resolve the permissions team id
     */
    'team_resolver' => \Spatie\Permission\DefaultTeamResolver::class,

    /*
     * Passport Client Credentials Grant
     * When set to true the package will use Passports Client to check permissions
     */

    'use_passport_client_credentials' => false,

    /*
     * When set to true, the required permission names are added to exception messages.
     * This could be considered an information leak in some contexts, so the default
     * setting is false here for optimum safety.
     */

    'display_permission_in_exception' => false,

    /*
     * When set to true, the required role names are added to exception messages.
     * This could be considered an information leak in some contexts, so the default
     * setting is false here for optimum safety.
     */

    'display_role_in_exception' => false,

    /*
     * By default wildcard permission lookups are disabled.
     * See documentation to understand supported syntax.
     */

    'enable_wildcard_permission' => false,

    /*
     * The class to use for interpreting wildcard permissions.
     * If you need to modify delimiters, override the class and specify its name here.
     */
    // 'wildcard_permission' => Spatie\Permission\WildcardPermission::class,

    /* Cache-specific settings */

    'cache' => [

        /*
         * By default all permissions are cached for 24 hours to speed up performance.
         * When permissions or roles are updated the cache is flushed automatically.
         */

        'expiration_time' => \DateInterval::createFromDateString('24 hours'),

        /*
         * The cache key used to store all permissions.
         */

        'key' => 'spatie.permission.cache',

        /*
         * You may optionally indicate a specific cache driver to use for permission and
         * role caching using any of the `store` drivers listed in the cache.php config
         * file. Using 'default' here means to use the `default` set in cache.php.
         */

        'store' => 'default',
    ],
];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/config/filesystems.php ---
<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Default Filesystem Disk
    |--------------------------------------------------------------------------
    |
    | Here you may specify the default filesystem disk that should be used
    | by the framework. The "local" disk, as well as a variety of cloud
    | based disks are available to your application for file storage.
    |
    */

    'default' => env('FILESYSTEM_DISK', 'local'),

    /*
    |--------------------------------------------------------------------------
    | Filesystem Disks
    |--------------------------------------------------------------------------
    |
    | Below you may configure as many filesystem disks as necessary, and you
    | may even configure multiple disks for the same driver. Examples for
    | most supported storage drivers are configured here for reference.
    |
    | Supported drivers: "local", "ftp", "sftp", "s3"
    |
    */

    'disks' => [

        'local' => [
            'driver' => 'local',
            'root' => storage_path('app/private'),
            'serve' => true,
            'throw' => false,
            'report' => false,
        ],

        'public' => [
            'driver' => 'local',
            'root' => storage_path('app/public'),
            'url' => env('APP_URL').'/storage',
            'visibility' => 'public',
            'throw' => false,
            'report' => false,
        ],

        's3' => [
            'driver' => 's3',
            'key' => env('AWS_ACCESS_KEY_ID'),
            'secret' => env('AWS_SECRET_ACCESS_KEY'),
            'region' => env('AWS_DEFAULT_REGION'),
            'bucket' => env('AWS_BUCKET'),
            'url' => env('AWS_URL'),
            'endpoint' => env('AWS_ENDPOINT'),
            'use_path_style_endpoint' => env('AWS_USE_PATH_STYLE_ENDPOINT', false),
            'throw' => false,
            'report' => false,
        ],

    ],

    /*
    |--------------------------------------------------------------------------
    | Symbolic Links
    |--------------------------------------------------------------------------
    |
    | Here you may configure the symbolic links that will be created when the
    | `storage:link` Artisan command is executed. The array keys should be
    | the locations of the links and the values should be their targets.
    |
    */

    'links' => [
        public_path('storage') => storage_path('app/public'),
    ],

];

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/js/bootstrap.js ---
import axios from 'axios';
window.axios = axios;

window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/js/app.js ---
import './bootstrap';

import Alpine from 'alpinejs';

window.Alpine = Alpine;

Alpine.start();

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/welcome.blade.php ---
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <title>{{ config('app.name', 'Laravel') }}</title>

    <!-- Fonts -->
    <link rel="preconnect" href="https://fonts.bunny.net">
    <link href="https://fonts.bunny.net/css?family=instrument-sans:400,500,600" rel="stylesheet" />

    <!-- Styles / Scripts -->
    @if (file_exists(public_path('build/manifest.json')) || file_exists(public_path('hot')))
        @vite(['resources/css/app.css', 'resources/js/app.js'])
    @else
        <style>
            /*! tailwindcss v4.0.7 | MIT License | https://tailwindcss.com */
            @layer theme {

                :root,
                :host {
                    --font-sans: 'Instrument Sans', ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
                    --font-serif: ui-serif, Georgia, Cambria, "Times New Roman", Times, serif;
                    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
                    --color-red-50: oklch(.971 .013 17.38);
                    --color-red-100: oklch(.936 .032 17.717);
                    --color-red-200: oklch(.885 .062 18.334);
                    --color-red-300: oklch(.808 .114 19.571);
                    --color-red-400: oklch(.704 .191 22.216);
                    --color-red-500: oklch(.637 .237 25.331);
                    --color-red-600: oklch(.577 .245 27.325);
                    --color-red-700: oklch(.505 .213 27.518);
                    --color-red-800: oklch(.444 .177 26.899);
                    --color-red-900: oklch(.396 .141 25.723);
                    --color-red-950: oklch(.258 .092 26.042);
                    --color-orange-50: oklch(.98 .016 73.684);
                    --color-orange-100: oklch(.954 .038 75.164);
                    --color-orange-200: oklch(.901 .076 70.697);
                    --color-orange-300: oklch(.837 .128 66.29);
                    --color-orange-400: oklch(.75 .183 55.934);
                    --color-orange-500: oklch(.705 .213 47.604);
                    --color-orange-600: oklch(.646 .222 41.116);
                    --color-orange-700: oklch(.553 .195 38.402);
                    --color-orange-800: oklch(.47 .157 37.304);
                    --color-orange-900: oklch(.408 .123 38.172);
                    --color-orange-950: oklch(.266 .079 36.259);
                    --color-amber-50: oklch(.987 .022 95.277);
                    --color-amber-100: oklch(.962 .059 95.617);
                    --color-amber-200: oklch(.924 .12 95.746);
                    --color-amber-300: oklch(.879 .169 91.605);
                    --color-amber-400: oklch(.828 .189 84.429);
                    --color-amber-500: oklch(.769 .188 70.08);
                    --color-amber-600: oklch(.666 .179 58.318);
                    --color-amber-700: oklch(.555 .163 48.998);
                    --color-amber-800: oklch(.473 .137 46.201);
                    --color-amber-900: oklch(.414 .112 45.904);
                    --color-amber-950: oklch(.279 .077 45.635);
                    --color-yellow-50: oklch(.987 .026 102.212);
                    --color-yellow-100: oklch(.973 .071 103.193);
                    --color-yellow-200: oklch(.945 .129 101.54);
                    --color-yellow-300: oklch(.905 .182 98.111);
                    --color-yellow-400: oklch(.852 .199 91.936);
                    --color-yellow-500: oklch(.795 .184 86.047);
                    --color-yellow-600: oklch(.681 .162 75.834);
                    --color-yellow-700: oklch(.554 .135 66.442);
                    --color-yellow-800: oklch(.476 .114 61.907);
                    --color-yellow-900: oklch(.421 .095 57.708);
                    --color-yellow-950: oklch(.286 .066 53.813);
                    --color-lime-50: oklch(.986 .031 120.757);
                    --color-lime-100: oklch(.967 .067 122.328);
                    --color-lime-200: oklch(.938 .127 124.321);
                    --color-lime-300: oklch(.897 .196 126.665);
                    --color-lime-400: oklch(.841 .238 128.85);
                    --color-lime-500: oklch(.768 .233 130.85);
                    --color-lime-600: oklch(.648 .2 131.684);
                    --color-lime-700: oklch(.532 .157 131.589);
                    --color-lime-800: oklch(.453 .124 130.933);
                    --color-lime-900: oklch(.405 .101 131.063);
                    --color-lime-950: oklch(.274 .072 132.109);
                    --color-green-50: oklch(.982 .018 155.826);
                    --color-green-100: oklch(.962 .044 156.743);
                    --color-green-200: oklch(.925 .084 155.995);
                    --color-green-300: oklch(.871 .15 154.449);
                    --color-green-400: oklch(.792 .209 151.711);
                    --color-green-500: oklch(.723 .219 149.579);
                    --color-green-600: oklch(.627 .194 149.214);
                    --color-green-700: oklch(.527 .154 150.069);
                    --color-green-800: oklch(.448 .119 151.328);
                    --color-green-900: oklch(.393 .095 152.535);
                    --color-green-950: oklch(.266 .065 152.934);
                    --color-emerald-50: oklch(.979 .021 166.113);
                    --color-emerald-100: oklch(.95 .052 163.051);
                    --color-emerald-200: oklch(.905 .093 164.15);
                    --color-emerald-300: oklch(.845 .143 164.978);
                    --color-emerald-400: oklch(.765 .177 163.223);
                    --color-emerald-500: oklch(.696 .17 162.48);
                    --color-emerald-600: oklch(.596 .145 163.225);
                    --color-emerald-700: oklch(.508 .118 165.612);
                    --color-emerald-800: oklch(.432 .095 166.913);
                    --color-emerald-900: oklch(.378 .077 168.94);
                    --color-emerald-950: oklch(.262 .051 172.552);
                    --color-teal-50: oklch(.984 .014 180.72);
                    --color-teal-100: oklch(.953 .051 180.801);
                    --color-teal-200: oklch(.91 .096 180.426);
                    --color-teal-300: oklch(.855 .138 181.071);
                    --color-teal-400: oklch(.777 .152 181.912);
                    --color-teal-500: oklch(.704 .14 182.503);
                    --color-teal-600: oklch(.6 .118 184.704);
                    --color-teal-700: oklch(.511 .096 186.391);
                    --color-teal-800: oklch(.437 .078 188.216);
                    --color-teal-900: oklch(.386 .063 188.416);
                    --color-teal-950: oklch(.277 .046 192.524);
                    --color-cyan-50: oklch(.984 .019 200.873);
                    --color-cyan-100: oklch(.956 .045 203.388);
                    --color-cyan-200: oklch(.917 .08 205.041);
                    --color-cyan-300: oklch(.865 .127 207.078);
                    --color-cyan-400: oklch(.789 .154 211.53);
                    --color-cyan-500: oklch(.715 .143 215.221);
                    --color-cyan-600: oklch(.609 .126 221.723);
                    --color-cyan-700: oklch(.52 .105 223.128);
                    --color-cyan-800: oklch(.45 .085 224.283);
                    --color-cyan-900: oklch(.398 .07 227.392);
                    --color-cyan-950: oklch(.302 .056 229.695);
                    --color-sky-50: oklch(.977 .013 236.62);
                    --color-sky-100: oklch(.951 .026 236.824);
                    --color-sky-200: oklch(.901 .058 230.902);
                    --color-sky-300: oklch(.828 .111 230.318);
                    --color-sky-400: oklch(.746 .16 232.661);
                    --color-sky-500: oklch(.685 .169 237.323);
                    --color-sky-600: oklch(.588 .158 241.966);
                    --color-sky-700: oklch(.5 .134 242.749);
                    --color-sky-800: oklch(.443 .11 240.79);
                    --color-sky-900: oklch(.391 .09 240.876);
                    --color-sky-950: oklch(.293 .066 243.157);
                    --color-blue-50: oklch(.97 .014 254.604);
                    --color-blue-100: oklch(.932 .032 255.585);
                    --color-blue-200: oklch(.882 .059 254.128);
                    --color-blue-300: oklch(.809 .105 251.813);
                    --color-blue-400: oklch(.707 .165 254.624);
                    --color-blue-500: oklch(.623 .214 259.815);
                    --color-blue-600: oklch(.546 .245 262.881);
                    --color-blue-700: oklch(.488 .243 264.376);
                    --color-blue-800: oklch(.424 .199 265.638);
                    --color-blue-900: oklch(.379 .146 265.522);
                    --color-blue-950: oklch(.282 .091 267.935);
                    --color-indigo-50: oklch(.962 .018 272.314);
                    --color-indigo-100: oklch(.93 .034 272.788);
                    --color-indigo-200: oklch(.87 .065 274.039);
                    --color-indigo-300: oklch(.785 .115 274.713);
                    --color-indigo-400: oklch(.673 .182 276.935);
                    --color-indigo-500: oklch(.585 .233 277.117);
                    --color-indigo-600: oklch(.511 .262 276.966);
                    --color-indigo-700: oklch(.457 .24 277.023);
                    --color-indigo-800: oklch(.398 .195 277.366);
                    --color-indigo-900: oklch(.359 .144 278.697);
                    --color-indigo-950: oklch(.257 .09 281.288);
                    --color-violet-50: oklch(.969 .016 293.756);
                    --color-violet-100: oklch(.943 .029 294.588);
                    --color-violet-200: oklch(.894 .057 293.283);
                    --color-violet-300: oklch(.811 .111 293.571);
                    --color-violet-400: oklch(.702 .183 293.541);
                    --color-violet-500: oklch(.606 .25 292.717);
                    --color-violet-600: oklch(.541 .281 293.009);
                    --color-violet-700: oklch(.491 .27 292.581);
                    --color-violet-800: oklch(.432 .232 292.759);
                    --color-violet-900: oklch(.38 .189 293.745);
                    --color-violet-950: oklch(.283 .141 291.089);
                    --color-purple-50: oklch(.977 .014 308.299);
                    --color-purple-100: oklch(.946 .033 307.174);
                    --color-purple-200: oklch(.902 .063 306.703);
                    --color-purple-300: oklch(.827 .119 306.383);
                    --color-purple-400: oklch(.714 .203 305.504);
                    --color-purple-500: oklch(.627 .265 303.9);
                    --color-purple-600: oklch(.558 .288 302.321);
                    --color-purple-700: oklch(.496 .265 301.924);
                    --color-purple-800: oklch(.438 .218 303.724);
                    --color-purple-900: oklch(.381 .176 304.987);
                    --color-purple-950: oklch(.291 .149 302.717);
                    --color-fuchsia-50: oklch(.977 .017 320.058);
                    --color-fuchsia-100: oklch(.952 .037 318.852);
                    --color-fuchsia-200: oklch(.903 .076 319.62);
                    --color-fuchsia-300: oklch(.833 .145 321.434);
                    --color-fuchsia-400: oklch(.74 .238 322.16);
                    --color-fuchsia-500: oklch(.667 .295 322.15);
                    --color-fuchsia-600: oklch(.591 .293 322.896);
                    --color-fuchsia-700: oklch(.518 .253 323.949);
                    --color-fuchsia-800: oklch(.452 .211 324.591);
                    --color-fuchsia-900: oklch(.401 .17 325.612);
                    --color-fuchsia-950: oklch(.293 .136 325.661);
                    --color-pink-50: oklch(.971 .014 343.198);
                    --color-pink-100: oklch(.948 .028 342.258);
                    --color-pink-200: oklch(.899 .061 343.231);
                    --color-pink-300: oklch(.823 .12 346.018);
                    --color-pink-400: oklch(.718 .202 349.761);
                    --color-pink-500: oklch(.656 .241 354.308);
                    --color-pink-600: oklch(.592 .249 .584);
                    --color-pink-700: oklch(.525 .223 3.958);
                    --color-pink-800: oklch(.459 .187 3.815);
                    --color-pink-900: oklch(.408 .153 2.432);
                    --color-pink-950: oklch(.284 .109 3.907);
                    --color-rose-50: oklch(.969 .015 12.422);
                    --color-rose-100: oklch(.941 .03 12.58);
                    --color-rose-200: oklch(.892 .058 10.001);
                    --color-rose-300: oklch(.81 .117 11.638);
                    --color-rose-400: oklch(.712 .194 13.428);
                    --color-rose-500: oklch(.645 .246 16.439);
                    --color-rose-600: oklch(.586 .253 17.585);
                    --color-rose-700: oklch(.514 .222 16.935);
                    --color-rose-800: oklch(.455 .188 13.697);
                    --color-rose-900: oklch(.41 .159 10.272);
                    --color-rose-950: oklch(.271 .105 12.094);
                    --color-slate-50: oklch(.984 .003 247.858);
                    --color-slate-100: oklch(.968 .007 247.896);
                    --color-slate-200: oklch(.929 .013 255.508);
                    --color-slate-300: oklch(.869 .022 252.894);
                    --color-slate-400: oklch(.704 .04 256.788);
                    --color-slate-500: oklch(.554 .046 257.417);
                    --color-slate-600: oklch(.446 .043 257.281);
                    --color-slate-700: oklch(.372 .044 257.287);
                    --color-slate-800: oklch(.279 .041 260.031);
                    --color-slate-900: oklch(.208 .042 265.755);
                    --color-slate-950: oklch(.129 .042 264.695);
                    --color-gray-50: oklch(.985 .002 247.839);
                    --color-gray-100: oklch(.967 .003 264.542);
                    --color-gray-200: oklch(.928 .006 264.531);
                    --color-gray-300: oklch(.872 .01 258.338);
                    --color-gray-400: oklch(.707 .022 261.325);
                    --color-gray-500: oklch(.551 .027 264.364);
                    --color-gray-600: oklch(.446 .03 256.802);
                    --color-gray-700: oklch(.373 .034 259.733);
                    --color-gray-800: oklch(.278 .033 256.848);
                    --color-gray-900: oklch(.21 .034 264.665);
                    --color-gray-950: oklch(.13 .028 261.692);
                    --color-zinc-50: oklch(.985 0 0);
                    --color-zinc-100: oklch(.967 .001 286.375);
                    --color-zinc-200: oklch(.92 .004 286.32);
                    --color-zinc-300: oklch(.871 .006 286.286);
                    --color-zinc-400: oklch(.705 .015 286.067);
                    --color-zinc-500: oklch(.552 .016 285.938);
                    --color-zinc-600: oklch(.442 .017 285.786);
                    --color-zinc-700: oklch(.37 .013 285.805);
                    --color-zinc-800: oklch(.274 .006 286.033);
                    --color-zinc-900: oklch(.21 .006 285.885);
                    --color-zinc-950: oklch(.141 .005 285.823);
                    --color-neutral-50: oklch(.985 0 0);
                    --color-neutral-100: oklch(.97 0 0);
                    --color-neutral-200: oklch(.922 0 0);
                    --color-neutral-300: oklch(.87 0 0);
                    --color-neutral-400: oklch(.708 0 0);
                    --color-neutral-500: oklch(.556 0 0);
                    --color-neutral-600: oklch(.439 0 0);
                    --color-neutral-700: oklch(.371 0 0);
                    --color-neutral-800: oklch(.269 0 0);
                    --color-neutral-900: oklch(.205 0 0);
                    --color-neutral-950: oklch(.145 0 0);
                    --color-stone-50: oklch(.985 .001 106.423);
                    --color-stone-100: oklch(.97 .001 106.424);
                    --color-stone-200: oklch(.923 .003 48.717);
                    --color-stone-300: oklch(.869 .005 56.366);
                    --color-stone-400: oklch(.709 .01 56.259);
                    --color-stone-500: oklch(.553 .013 58.071);
                    --color-stone-600: oklch(.444 .011 73.639);
                    --color-stone-700: oklch(.374 .01 67.558);
                    --color-stone-800: oklch(.268 .007 34.298);
                    --color-stone-900: oklch(.216 .006 56.043);
                    --color-stone-950: oklch(.147 .004 49.25);
                    --color-black: #000;
                    --color-white: #fff;
                    --spacing: .25rem;
                    --breakpoint-sm: 40rem;
                    --breakpoint-md: 48rem;
                    --breakpoint-lg: 64rem;
                    --breakpoint-xl: 80rem;
                    --breakpoint-2xl: 96rem;
                    --container-3xs: 16rem;
                    --container-2xs: 18rem;
                    --container-xs: 20rem;
                    --container-sm: 24rem;
                    --container-md: 28rem;
                    --container-lg: 32rem;
                    --container-xl: 36rem;
                    --container-2xl: 42rem;
                    --container-3xl: 48rem;
                    --container-4xl: 56rem;
                    --container-5xl: 64rem;
                    --container-6xl: 72rem;
                    --container-7xl: 80rem;
                    --text-xs: .75rem;
                    --text-xs--line-height: calc(1/.75);
                    --text-sm: .875rem;
                    --text-sm--line-height: calc(1.25/.875);
                    --text-base: 1rem;
                    --text-base--line-height: 1.5;
                    --text-lg: 1.125rem;
                    --text-lg--line-height: calc(1.75/1.125);
                    --text-xl: 1.25rem;
                    --text-xl--line-height: calc(1.75/1.25);
                    --text-2xl: 1.5rem;
                    --text-2xl--line-height: calc(2/1.5);
                    --text-3xl: 1.875rem;
                    --text-3xl--line-height: 1.2;
                    --text-4xl: 2.25rem;
                    --text-4xl--line-height: calc(2.5/2.25);
                    --text-5xl: 3rem;
                    --text-5xl--line-height: 1;
                    --text-6xl: 3.75rem;
                    --text-6xl--line-height: 1;
                    --text-7xl: 4.5rem;
                    --text-7xl--line-height: 1;
                    --text-8xl: 6rem;
                    --text-8xl--line-height: 1;
                    --text-9xl: 8rem;
                    --text-9xl--line-height: 1;
                    --font-weight-thin: 100;
                    --font-weight-extralight: 200;
                    --font-weight-light: 300;
                    --font-weight-normal: 400;
                    --font-weight-medium: 500;
                    --font-weight-semibold: 600;
                    --font-weight-bold: 700;
                    --font-weight-extrabold: 800;
                    --font-weight-black: 900;
                    --tracking-tighter: -.05em;
                    --tracking-tight: -.025em;
                    --tracking-normal: 0em;
                    --tracking-wide: .025em;
                    --tracking-wider: .05em;
                    --tracking-widest: .1em;
                    --leading-tight: 1.25;
                    --leading-snug: 1.375;
                    --leading-normal: 1.5;
                    --leading-relaxed: 1.625;
                    --leading-loose: 2;
                    --radius-xs: .125rem;
                    --radius-sm: .25rem;
                    --radius-md: .375rem;
                    --radius-lg: .5rem;
                    --radius-xl: .75rem;
                    --radius-2xl: 1rem;
                    --radius-3xl: 1.5rem;
                    --radius-4xl: 2rem;
                    --shadow-2xs: 0 1px #0000000d;
                    --shadow-xs: 0 1px 2px 0 #0000000d;
                    --shadow-sm: 0 1px 3px 0 #0000001a, 0 1px 2px -1px #0000001a;
                    --shadow-md: 0 4px 6px -1px #0000001a, 0 2px 4px -2px #0000001a;
                    --shadow-lg: 0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;
                    --shadow-xl: 0 20px 25px -5px #0000001a, 0 8px 10px -6px #0000001a;
                    --shadow-2xl: 0 25px 50px -12px #00000040;
                    --inset-shadow-2xs: inset 0 1px #0000000d;
                    --inset-shadow-xs: inset 0 1px 1px #0000000d;
                    --inset-shadow-sm: inset 0 2px 4px #0000000d;
                    --drop-shadow-xs: 0 1px 1px #0000000d;
                    --drop-shadow-sm: 0 1px 2px #00000026;
                    --drop-shadow-md: 0 3px 3px #0000001f;
                    --drop-shadow-lg: 0 4px 4px #00000026;
                    --drop-shadow-xl: 0 9px 7px #0000001a;
                    --drop-shadow-2xl: 0 25px 25px #00000026;
                    --ease-in: cubic-bezier(.4, 0, 1, 1);
                    --ease-out: cubic-bezier(0, 0, .2, 1);
                    --ease-in-out: cubic-bezier(.4, 0, .2, 1);
                    --animate-spin: spin 1s linear infinite;
                    --animate-ping: ping 1s cubic-bezier(0, 0, .2, 1)infinite;
                    --animate-pulse: pulse 2s cubic-bezier(.4, 0, .6, 1)infinite;
                    --animate-bounce: bounce 1s infinite;
                    --blur-xs: 4px;
                    --blur-sm: 8px;
                    --blur-md: 12px;
                    --blur-lg: 16px;
                    --blur-xl: 24px;
                    --blur-2xl: 40px;
                    --blur-3xl: 64px;
                    --perspective-dramatic: 100px;
                    --perspective-near: 300px;
                    --perspective-normal: 500px;
                    --perspective-midrange: 800px;
                    --perspective-distant: 1200px;
                    --aspect-video: 16/9;
                    --default-transition-duration: .15s;
                    --default-transition-timing-function: cubic-bezier(.4, 0, .2, 1);
                    --default-font-family: var(--font-sans);
                    --default-font-feature-settings: var(--font-sans--font-feature-settings);
                    --default-font-variation-settings: var(--font-sans--font-variation-settings);
                    --default-mono-font-family: var(--font-mono);
                    --default-mono-font-feature-settings: var(--font-mono--font-feature-settings);
                    --default-mono-font-variation-settings: var(--font-mono--font-variation-settings)
                }
            }

            @layer base {

                *,
                :after,
                :before,
                ::backdrop {
                    box-sizing: border-box;
                    border: 0 solid;
                    margin: 0;
                    padding: 0
                }

                ::file-selector-button {
                    box-sizing: border-box;
                    border: 0 solid;
                    margin: 0;
                    padding: 0
                }

                html,
                :host {
                    -webkit-text-size-adjust: 100%;
                    -moz-tab-size: 4;
                    tab-size: 4;
                    line-height: 1.5;
                    font-family: var(--default-font-family, ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");
                    font-feature-settings: var(--default-font-feature-settings, normal);
                    font-variation-settings: var(--default-font-variation-settings, normal);
                    -webkit-tap-highlight-color: transparent
                }

                body {
                    line-height: inherit
                }

                hr {
                    height: 0;
                    color: inherit;
                    border-top-width: 1px
                }

                abbr:where([title]) {
                    -webkit-text-decoration: underline dotted;
                    text-decoration: underline dotted
                }

                h1,
                h2,
                h3,
                h4,
                h5,
                h6 {
                    font-size: inherit;
                    font-weight: inherit
                }

                a {
                    color: inherit;
                    -webkit-text-decoration: inherit;
                    text-decoration: inherit
                }

                b,
                strong {
                    font-weight: bolder
                }

                code,
                kbd,
                samp,
                pre {
                    font-family: var(--default-mono-font-family, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);
                    font-feature-settings: var(--default-mono-font-feature-settings, normal);
                    font-variation-settings: var(--default-mono-font-variation-settings, normal);
                    font-size: 1em
                }

                small {
                    font-size: 80%
                }

                sub,
                sup {
                    vertical-align: baseline;
                    font-size: 75%;
                    line-height: 0;
                    position: relative
                }

                sub {
                    bottom: -.25em
                }

                sup {
                    top: -.5em
                }

                table {
                    text-indent: 0;
                    border-color: inherit;
                    border-collapse: collapse
                }

                :-moz-focusring {
                    outline: auto
                }

                progress {
                    vertical-align: baseline
                }

                summary {
                    display: list-item
                }

                ol,
                ul,
                menu {
                    list-style: none
                }

                img,
                svg,
                video,
                canvas,
                audio,
                iframe,
                embed,
                object {
                    vertical-align: middle;
                    display: block
                }

                img,
                video {
                    max-width: 100%;
                    height: auto
                }

                button,
                input,
                select,
                optgroup,
                textarea {
                    font: inherit;
                    font-feature-settings: inherit;
                    font-variation-settings: inherit;
                    letter-spacing: inherit;
                    color: inherit;
                    opacity: 1;
                    background-color: #0000;
                    border-radius: 0
                }

                ::file-selector-button {
                    font: inherit;
                    font-feature-settings: inherit;
                    font-variation-settings: inherit;
                    letter-spacing: inherit;
                    color: inherit;
                    opacity: 1;
                    background-color: #0000;
                    border-radius: 0
                }

                :where(select:is([multiple], [size])) optgroup {
                    font-weight: bolder
                }

                :where(select:is([multiple], [size])) optgroup option {
                    padding-inline-start: 20px
                }

                ::file-selector-button {
                    margin-inline-end: 4px
                }

                ::placeholder {
                    opacity: 1;
                    color: color-mix(in oklab, currentColor 50%, transparent)
                }

                textarea {
                    resize: vertical
                }

                ::-webkit-search-decoration {
                    -webkit-appearance: none
                }

                ::-webkit-date-and-time-value {
                    min-height: 1lh;
                    text-align: inherit
                }

                ::-webkit-datetime-edit {
                    display: inline-flex
                }

                ::-webkit-datetime-edit-fields-wrapper {
                    padding: 0
                }

                ::-webkit-datetime-edit {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-year-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-month-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-day-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-hour-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-minute-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-second-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-millisecond-field {
                    padding-block: 0
                }

                ::-webkit-datetime-edit-meridiem-field {
                    padding-block: 0
                }

                :-moz-ui-invalid {
                    box-shadow: none
                }

                button,
                input:where([type=button], [type=reset], [type=submit]) {
                    -webkit-appearance: button;
                    -moz-appearance: button;
                    appearance: button
                }

                ::file-selector-button {
                    -webkit-appearance: button;
                    -moz-appearance: button;
                    appearance: button
                }

                ::-webkit-inner-spin-button {
                    height: auto
                }

                ::-webkit-outer-spin-button {
                    height: auto
                }

                [hidden]:where(:not([hidden=until-found])) {
                    display: none !important
                }
            }

            @layer components;

            @layer utilities {
                .absolute {
                    position: absolute
                }

                .relative {
                    position: relative
                }

                .static {
                    position: static
                }

                .inset-0 {
                    inset: calc(var(--spacing)*0)
                }

                .-mt-\[4\.9rem\] {
                    margin-top: -4.9rem
                }

                .-mb-px {
                    margin-bottom: -1px
                }

                .mb-1 {
                    margin-bottom: calc(var(--spacing)*1)
                }

                .mb-2 {
                    margin-bottom: calc(var(--spacing)*2)
                }

                .mb-4 {
                    margin-bottom: calc(var(--spacing)*4)
                }

                .mb-6 {
                    margin-bottom: calc(var(--spacing)*6)
                }

                .-ml-8 {
                    margin-left: calc(var(--spacing)*-8)
                }

                .flex {
                    display: flex
                }

                .hidden {
                    display: none
                }

                .inline-block {
                    display: inline-block
                }

                .inline-flex {
                    display: inline-flex
                }

                .table {
                    display: table
                }

                .aspect-\[335\/376\] {
                    aspect-ratio: 335/376
                }

                .h-1 {
                    height: calc(var(--spacing)*1)
                }

                .h-1\.5 {
                    height: calc(var(--spacing)*1.5)
                }

                .h-2 {
                    height: calc(var(--spacing)*2)
                }

                .h-2\.5 {
                    height: calc(var(--spacing)*2.5)
                }

                .h-3 {
                    height: calc(var(--spacing)*3)
                }

                .h-3\.5 {
                    height: calc(var(--spacing)*3.5)
                }

                .h-14 {
                    height: calc(var(--spacing)*14)
                }

                .h-14\.5 {
                    height: calc(var(--spacing)*14.5)
                }

                .min-h-screen {
                    min-height: 100vh
                }

                .w-1 {
                    width: calc(var(--spacing)*1)
                }

                .w-1\.5 {
                    width: calc(var(--spacing)*1.5)
                }

                .w-2 {
                    width: calc(var(--spacing)*2)
                }

                .w-2\.5 {
                    width: calc(var(--spacing)*2.5)
                }

                .w-3 {
                    width: calc(var(--spacing)*3)
                }

                .w-3\.5 {
                    width: calc(var(--spacing)*3.5)
                }

                .w-\[448px\] {
                    width: 448px
                }

                .w-full {
                    width: 100%
                }

                .max-w-\[335px\] {
                    max-width: 335px
                }

                .max-w-none {
                    max-width: none
                }

                .flex-1 {
                    flex: 1
                }

                .shrink-0 {
                    flex-shrink: 0
                }

                .translate-y-0 {
                    --tw-translate-y: calc(var(--spacing)*0);
                    translate: var(--tw-translate-x)var(--tw-translate-y)
                }

                .transform {
                    transform: var(--tw-rotate-x)var(--tw-rotate-y)var(--tw-rotate-z)var(--tw-skew-x)var(--tw-skew-y)
                }

                .flex-col {
                    flex-direction: column
                }

                .flex-col-reverse {
                    flex-direction: column-reverse
                }

                .items-center {
                    align-items: center
                }

                .justify-center {
                    justify-content: center
                }

                .justify-end {
                    justify-content: flex-end
                }

                .gap-3 {
                    gap: calc(var(--spacing)*3)
                }

                .gap-4 {
                    gap: calc(var(--spacing)*4)
                }

                :where(.space-x-1>:not(:last-child)) {
                    --tw-space-x-reverse: 0;
                    margin-inline-start: calc(calc(var(--spacing)*1)*var(--tw-space-x-reverse));
                    margin-inline-end: calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-x-reverse)))
                }

                .overflow-hidden {
                    overflow: hidden
                }

                .rounded-full {
                    border-radius: 3.40282e38px
                }

                .rounded-sm {
                    border-radius: var(--radius-sm)
                }

                .rounded-t-lg {
                    border-top-left-radius: var(--radius-lg);
                    border-top-right-radius: var(--radius-lg)
                }

                .rounded-br-lg {
                    border-bottom-right-radius: var(--radius-lg)
                }

                .rounded-bl-lg {
                    border-bottom-left-radius: var(--radius-lg)
                }

                .border {
                    border-style: var(--tw-border-style);
                    border-width: 1px
                }

                .border-\[\#19140035\] {
                    border-color: #19140035
                }

                .border-\[\#e3e3e0\] {
                    border-color: #e3e3e0
                }

                .border-black {
                    border-color: var(--color-black)
                }

                .border-transparent {
                    border-color: #0000
                }

                .bg-\[\#1b1b18\] {
                    background-color: #1b1b18
                }

                .bg-\[\#FDFDFC\] {
                    background-color: #fdfdfc
                }

                .bg-\[\#dbdbd7\] {
                    background-color: #dbdbd7
                }

                .bg-\[\#fff2f2\] {
                    background-color: #fff2f2
                }

                .bg-white {
                    background-color: var(--color-white)
                }

                .p-6 {
                    padding: calc(var(--spacing)*6)
                }

                .px-5 {
                    padding-inline: calc(var(--spacing)*5)
                }

                .py-1 {
                    padding-block: calc(var(--spacing)*1)
                }

                .py-1\.5 {
                    padding-block: calc(var(--spacing)*1.5)
                }

                .py-2 {
                    padding-block: calc(var(--spacing)*2)
                }

                .pb-12 {
                    padding-bottom: calc(var(--spacing)*12)
                }

                .text-sm {
                    font-size: var(--text-sm);
                    line-height: var(--tw-leading, var(--text-sm--line-height))
                }

                .text-\[13px\] {
                    font-size: 13px
                }

                .leading-\[20px\] {
                    --tw-leading: 20px;
                    line-height: 20px
                }

                .leading-normal {
                    --tw-leading: var(--leading-normal);
                    line-height: var(--leading-normal)
                }

                .font-medium {
                    --tw-font-weight: var(--font-weight-medium);
                    font-weight: var(--font-weight-medium)
                }

                .text-\[\#1b1b18\] {
                    color: #1b1b18
                }

                .text-\[\#706f6c\] {
                    color: #706f6c
                }

                .text-\[\#F53003\],
                .text-\[\#f53003\] {
                    color: #f53003
                }

                .text-white {
                    color: var(--color-white)
                }

                .underline {
                    text-decoration-line: underline
                }

                .underline-offset-4 {
                    text-underline-offset: 4px
                }

                .opacity-100 {
                    opacity: 1
                }

                .shadow-\[0px_0px_1px_0px_rgba\(0\,0\,0\,0\.03\)\,0px_1px_2px_0px_rgba\(0\,0\,0\,0\.06\)\] {
                    --tw-shadow: 0px 0px 1px 0px var(--tw-shadow-color, #00000008), 0px 1px 2px 0px var(--tw-shadow-color, #0000000f);
                    box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)
                }

                .shadow-\[inset_0px_0px_0px_1px_rgba\(26\,26\,0\,0\.16\)\] {
                    --tw-shadow: inset 0px 0px 0px 1px var(--tw-shadow-color, #1a1a0029);
                    box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)
                }

                .\!filter {
                    filter: var(--tw-blur, )var(--tw-brightness, )var(--tw-contrast, )var(--tw-grayscale, )var(--tw-hue-rotate, )var(--tw-invert, )var(--tw-saturate, )var(--tw-sepia, )var(--tw-drop-shadow, ) !important
                }

                .filter {
                    filter: var(--tw-blur, )var(--tw-brightness, )var(--tw-contrast, )var(--tw-grayscale, )var(--tw-hue-rotate, )var(--tw-invert, )var(--tw-saturate, )var(--tw-sepia, )var(--tw-drop-shadow, )
                }

                .transition-all {
                    transition-property: all;
                    transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
                    transition-duration: var(--tw-duration, var(--default-transition-duration))
                }

                .transition-opacity {
                    transition-property: opacity;
                    transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
                    transition-duration: var(--tw-duration, var(--default-transition-duration))
                }

                .delay-300 {
                    transition-delay: .3s
                }

                .duration-750 {
                    --tw-duration: .75s;
                    transition-duration: .75s
                }

                .not-has-\[nav\]\:hidden:not(:has(:is(nav))) {
                    display: none
                }

                .before\:absolute:before {
                    content: var(--tw-content);
                    position: absolute
                }

                .before\:top-0:before {
                    content: var(--tw-content);
                    top: calc(var(--spacing)*0)
                }

                .before\:top-1\/2:before {
                    content: var(--tw-content);
                    top: 50%
                }

                .before\:bottom-0:before {
                    content: var(--tw-content);
                    bottom: calc(var(--spacing)*0)
                }

                .before\:bottom-1\/2:before {
                    content: var(--tw-content);
                    bottom: 50%
                }

                .before\:left-\[0\.4rem\]:before {
                    content: var(--tw-content);
                    left: .4rem
                }

                .before\:border-l:before {
                    content: var(--tw-content);
                    border-left-style: var(--tw-border-style);
                    border-left-width: 1px
                }

                .before\:border-\[\#e3e3e0\]:before {
                    content: var(--tw-content);
                    border-color: #e3e3e0
                }

                @media (hover:hover) {
                    .hover\:border-\[\#1915014a\]:hover {
                        border-color: #1915014a
                    }

                    .hover\:border-\[\#19140035\]:hover {
                        border-color: #19140035
                    }

                    .hover\:border-black:hover {
                        border-color: var(--color-black)
                    }

                    .hover\:bg-black:hover {
                        background-color: var(--color-black)
                    }
                }

                @media (width>=64rem) {
                    .lg\:-mt-\[6\.6rem\] {
                        margin-top: -6.6rem
                    }

                    .lg\:mb-0 {
                        margin-bottom: calc(var(--spacing)*0)
                    }

                    .lg\:mb-6 {
                        margin-bottom: calc(var(--spacing)*6)
                    }

                    .lg\:-ml-px {
                        margin-left: -1px
                    }

                    .lg\:ml-0 {
                        margin-left: calc(var(--spacing)*0)
                    }

                    .lg\:block {
                        display: block
                    }

                    .lg\:aspect-auto {
                        aspect-ratio: auto
                    }

                    .lg\:w-\[438px\] {
                        width: 438px
                    }

                    .lg\:max-w-4xl {
                        max-width: var(--container-4xl)
                    }

                    .lg\:grow {
                        flex-grow: 1
                    }

                    .lg\:flex-row {
                        flex-direction: row
                    }

                    .lg\:justify-center {
                        justify-content: center
                    }

                    .lg\:rounded-t-none {
                        border-top-left-radius: 0;
                        border-top-right-radius: 0
                    }

                    .lg\:rounded-tl-lg {
                        border-top-left-radius: var(--radius-lg)
                    }

                    .lg\:rounded-r-lg {
                        border-top-right-radius: var(--radius-lg);
                        border-bottom-right-radius: var(--radius-lg)
                    }

                    .lg\:rounded-br-none {
                        border-bottom-right-radius: 0
                    }

                    .lg\:p-8 {
                        padding: calc(var(--spacing)*8)
                    }

                    .lg\:p-20 {
                        padding: calc(var(--spacing)*20)
                    }
                }

                @media (prefers-color-scheme:dark) {
                    .dark\:block {
                        display: block
                    }

                    .dark\:hidden {
                        display: none
                    }

                    .dark\:border-\[\#3E3E3A\] {
                        border-color: #3e3e3a
                    }

                    .dark\:border-\[\#eeeeec\] {
                        border-color: #eeeeec
                    }

                    .dark\:bg-\[\#0a0a0a\] {
                        background-color: #0a0a0a
                    }

                    .dark\:bg-\[\#1D0002\] {
                        background-color: #1d0002
                    }

                    .dark\:bg-\[\#3E3E3A\] {
                        background-color: #3e3e3a
                    }

                    .dark\:bg-\[\#161615\] {
                        background-color: #161615
                    }

                    .dark\:bg-\[\#eeeeec\] {
                        background-color: #eeeeec
                    }

                    .dark\:text-\[\#1C1C1A\] {
                        color: #1c1c1a
                    }

                    .dark\:text-\[\#A1A09A\] {
                        color: #a1a09a
                    }

                    .dark\:text-\[\#EDEDEC\] {
                        color: #ededec
                    }

                    .dark\:text-\[\#F61500\] {
                        color: #f61500
                    }

                    .dark\:text-\[\#FF4433\] {
                        color: #f43
                    }

                    .dark\:shadow-\[inset_0px_0px_0px_1px_\#fffaed2d\] {
                        --tw-shadow: inset 0px 0px 0px 1px var(--tw-shadow-color, #fffaed2d);
                        box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)
                    }

                    .dark\:before\:border-\[\#3E3E3A\]:before {
                        content: var(--tw-content);
                        border-color: #3e3e3a
                    }

                    @media (hover:hover) {
                        .dark\:hover\:border-\[\#3E3E3A\]:hover {
                            border-color: #3e3e3a
                        }

                        .dark\:hover\:border-\[\#62605b\]:hover {
                            border-color: #62605b
                        }

                        .dark\:hover\:border-white:hover {
                            border-color: var(--color-white)
                        }

                        .dark\:hover\:bg-white:hover {
                            background-color: var(--color-white)
                        }
                    }
                }

                @starting-style {
                    .starting\:translate-y-4 {
                        --tw-translate-y: calc(var(--spacing)*4);
                        translate: var(--tw-translate-x)var(--tw-translate-y)
                    }
                }

                @starting-style {
                    .starting\:translate-y-6 {
                        --tw-translate-y: calc(var(--spacing)*6);
                        translate: var(--tw-translate-x)var(--tw-translate-y)
                    }
                }

                @starting-style {
                    .starting\:opacity-0 {
                        opacity: 0
                    }
                }
            }

            @keyframes spin {
                to {
                    transform: rotate(360deg)
                }
            }

            @keyframes ping {

                75%,
                to {
                    opacity: 0;
                    transform: scale(2)
                }
            }

            @keyframes pulse {
                50% {
                    opacity: .5
                }
            }

            @keyframes bounce {

                0%,
                to {
                    animation-timing-function: cubic-bezier(.8, 0, 1, 1);
                    transform: translateY(-25%)
                }

                50% {
                    animation-timing-function: cubic-bezier(0, 0, .2, 1);
                    transform: none
                }
            }

            @property --tw-translate-x {
                syntax: "*";
                inherits: false;
                initial-value: 0
            }

            @property --tw-translate-y {
                syntax: "*";
                inherits: false;
                initial-value: 0
            }

            @property --tw-translate-z {
                syntax: "*";
                inherits: false;
                initial-value: 0
            }

            @property --tw-rotate-x {
                syntax: "*";
                inherits: false;
                initial-value: rotateX(0)
            }

            @property --tw-rotate-y {
                syntax: "*";
                inherits: false;
                initial-value: rotateY(0)
            }

            @property --tw-rotate-z {
                syntax: "*";
                inherits: false;
                initial-value: rotateZ(0)
            }

            @property --tw-skew-x {
                syntax: "*";
                inherits: false;
                initial-value: skewX(0)
            }

            @property --tw-skew-y {
                syntax: "*";
                inherits: false;
                initial-value: skewY(0)
            }

            @property --tw-space-x-reverse {
                syntax: "*";
                inherits: false;
                initial-value: 0
            }

            @property --tw-border-style {
                syntax: "*";
                inherits: false;
                initial-value: solid
            }

            @property --tw-leading {
                syntax: "*";
                inherits: false
            }

            @property --tw-font-weight {
                syntax: "*";
                inherits: false
            }

            @property --tw-shadow {
                syntax: "*";
                inherits: false;
                initial-value: 0 0 #0000
            }

            @property --tw-shadow-color {
                syntax: "*";
                inherits: false
            }

            @property --tw-inset-shadow {
                syntax: "*";
                inherits: false;
                initial-value: 0 0 #0000
            }

            @property --tw-inset-shadow-color {
                syntax: "*";
                inherits: false
            }

            @property --tw-ring-color {
                syntax: "*";
                inherits: false
            }

            @property --tw-ring-shadow {
                syntax: "*";
                inherits: false;
                initial-value: 0 0 #0000
            }

            @property --tw-inset-ring-color {
                syntax: "*";
                inherits: false
            }

            @property --tw-inset-ring-shadow {
                syntax: "*";
                inherits: false;
                initial-value: 0 0 #0000
            }

            @property --tw-ring-inset {
                syntax: "*";
                inherits: false
            }

            @property --tw-ring-offset-width {
                syntax: "<length>";
                inherits: false;
                initial-value: 0
            }

            @property --tw-ring-offset-color {
                syntax: "*";
                inherits: false;
                initial-value: #fff
            }

            @property --tw-ring-offset-shadow {
                syntax: "*";
                inherits: false;
                initial-value: 0 0 #0000
            }

            @property --tw-blur {
                syntax: "*";
                inherits: false
            }

            @property --tw-brightness {
                syntax: "*";
                inherits: false
            }

            @property --tw-contrast {
                syntax: "*";
                inherits: false
            }

            @property --tw-grayscale {
                syntax: "*";
                inherits: false
            }

            @property --tw-hue-rotate {
                syntax: "*";
                inherits: false
            }

            @property --tw-invert {
                syntax: "*";
                inherits: false
            }

            @property --tw-opacity {
                syntax: "*";
                inherits: false
            }

            @property --tw-saturate {
                syntax: "*";
                inherits: false
            }

            @property --tw-sepia {
                syntax: "*";
                inherits: false
            }

            @property --tw-drop-shadow {
                syntax: "*";
                inherits: false
            }

            @property --tw-duration {
                syntax: "*";
                inherits: false
            }

            @property --tw-content {
                syntax: "*";
                inherits: false;
                initial-value: ""
            }
        </style>
    @endif
</head>

<body
    class="bg-[#FDFDFC] dark:bg-[#0a0a0a] text-[#1b1b18] flex p-6 lg:p-8 items-center lg:justify-center min-h-screen flex-col">
    <header class="w-full lg:max-w-4xl max-w-[335px] text-sm mb-6 not-has-[nav]:hidden">
        @if (Route::has('login'))
            <nav class="flex items-center justify-end gap-4">
                @auth
                    <a href="{{ url('/dashboard') }}"
                        class="inline-block px-5 py-1.5 dark:text-[#EDEDEC] border-[#19140035] hover:border-[#1915014a] border text-[#1b1b18] dark:border-[#3E3E3A] dark:hover:border-[#62605b] rounded-sm text-sm leading-normal">
                        Dashboard
                    </a>
                @else
                    <a href="{{ route('login') }}"
                        class="inline-block px-5 py-1.5 dark:text-[#EDEDEC] text-[#1b1b18] border border-transparent hover:border-[#19140035] dark:hover:border-[#3E3E3A] rounded-sm text-sm leading-normal">
                        Log in
                    </a>

                @endauth
            </nav>
        @endif
    </header>
    <div
        class="flex items-center justify-center w-full transition-opacity opacity-100 duration-750 lg:grow starting:opacity-0">
        <main class="flex max-w-[335px] w-full flex-col-reverse lg:max-w-4xl lg:flex-row">
            <div
                class="text-[13px] leading-[20px] flex-1 p-6 pb-12 lg:p-20 bg-white dark:bg-[#161615] dark:text-[#EDEDEC] shadow-[inset_0px_0px_0px_1px_rgba(26,26,0,0.16)] dark:shadow-[inset_0px_0px_0px_1px_#fffaed2d] rounded-bl-lg rounded-br-lg lg:rounded-tl-lg lg:rounded-br-none">
                <h1 class="mb-1 font-medium">Let's get started</h1>
                <p class="mb-2 text-[#706f6c] dark:text-[#A1A09A]">Laravel has an incredibly rich ecosystem. <br>We
                    suggest starting with the following.</p>
                <ul class="flex flex-col mb-4 lg:mb-6">
                    <li
                        class="flex items-center gap-4 py-2 relative before:border-l before:border-[#e3e3e0] dark:before:border-[#3E3E3A] before:top-1/2 before:bottom-0 before:left-[0.4rem] before:absolute">
                        <span class="relative py-1 bg-white dark:bg-[#161615]">
                            <span
                                class="flex items-center justify-center rounded-full bg-[#FDFDFC] dark:bg-[#161615] shadow-[0px_0px_1px_0px_rgba(0,0,0,0.03),0px_1px_2px_0px_rgba(0,0,0,0.06)] w-3.5 h-3.5 border dark:border-[#3E3E3A] border-[#e3e3e0]">
                                <span class="rounded-full bg-[#dbdbd7] dark:bg-[#3E3E3A] w-1.5 h-1.5"></span>
                            </span>
                        </span>
                        <span>
                            Read the
                            <a href="https://laravel.com/docs" target="_blank"
                                class="inline-flex items-center space-x-1 font-medium underline underline-offset-4 text-[#f53003] dark:text-[#FF4433] ml-1">
                                <span>Documentation</span>
                                <svg width="10" height="11" viewBox="0 0 10 11" fill="none"
                                    xmlns="http://www.w3.org/2000/svg" class="w-2.5 h-2.5">
                                    <path d="M7.70833 6.95834V2.79167H3.54167M2.5 8L7.5 3.00001" stroke="currentColor"
                                        stroke-linecap="square" />
                                </svg>
                            </a>
                        </span>
                    </li>
                    <li
                        class="flex items-center gap-4 py-2 relative before:border-l before:border-[#e3e3e0] dark:before:border-[#3E3E3A] before:bottom-1/2 before:top-0 before:left-[0.4rem] before:absolute">
                        <span class="relative py-1 bg-white dark:bg-[#161615]">
                            <span
                                class="flex items-center justify-center rounded-full bg-[#FDFDFC] dark:bg-[#161615] shadow-[0px_0px_1px_0px_rgba(0,0,0,0.03),0px_1px_2px_0px_rgba(0,0,0,0.06)] w-3.5 h-3.5 border dark:border-[#3E3E3A] border-[#e3e3e0]">
                                <span class="rounded-full bg-[#dbdbd7] dark:bg-[#3E3E3A] w-1.5 h-1.5"></span>
                            </span>
                        </span>
                        <span>
                            Watch video tutorials at
                            <a href="https://laracasts.com" target="_blank"
                                class="inline-flex items-center space-x-1 font-medium underline underline-offset-4 text-[#f53003] dark:text-[#FF4433] ml-1">
                                <span>Laracasts</span>
                                <svg width="10" height="11" viewBox="0 0 10 11" fill="none"
                                    xmlns="http://www.w3.org/2000/svg" class="w-2.5 h-2.5">
                                    <path d="M7.70833 6.95834V2.79167H3.54167M2.5 8L7.5 3.00001" stroke="currentColor"
                                        stroke-linecap="square" />
                                </svg>
                            </a>
                        </span>
                    </li>
                </ul>
                <ul class="flex gap-3 text-sm leading-normal">
                    <li>
                        <a href="https://cloud.laravel.com" target="_blank"
                            class="inline-block dark:bg-[#eeeeec] dark:border-[#eeeeec] dark:text-[#1C1C1A] dark:hover:bg-white dark:hover:border-white hover:bg-black hover:border-black px-5 py-1.5 bg-[#1b1b18] rounded-sm border border-black text-white text-sm leading-normal">
                            Deploy now
                        </a>
                    </li>
                </ul>
            </div>
            <div
                class="bg-[#fff2f2] dark:bg-[#1D0002] relative lg:-ml-px -mb-px lg:mb-0 rounded-t-lg lg:rounded-t-none lg:rounded-r-lg aspect-[335/376] lg:aspect-auto w-full lg:w-[438px] shrink-0 overflow-hidden">
                {{-- Laravel Logo --}}
                <svg class="w-full text-[#F53003] dark:text-[#F61500] transition-all translate-y-0 opacity-100 max-w-none duration-750 starting:opacity-0 starting:translate-y-6"
                    viewBox="0 0 438 104" fill="none" xmlns="http://www.w3.org/2000/svg">
                    <path d="M17.2036 -3H0V102.197H49.5189V86.7187H17.2036V-3Z" fill="currentColor" />
                    <path
                        d="M110.256 41.6337C108.061 38.1275 104.945 35.3731 100.905 33.3681C96.8667 31.3647 92.8016 30.3618 88.7131 30.3618C83.4247 30.3618 78.5885 31.3389 74.201 33.2923C69.8111 35.2456 66.0474 37.928 62.9059 41.3333C59.7643 44.7401 57.3198 48.6726 55.5754 53.1293C53.8287 57.589 52.9572 62.274 52.9572 67.1813C52.9572 72.1925 53.8287 76.8995 55.5754 81.3069C57.3191 85.7173 59.7636 89.6241 62.9059 93.0293C66.0474 96.4361 69.8119 99.1155 74.201 101.069C78.5885 103.022 83.4247 103.999 88.7131 103.999C92.8016 103.999 96.8667 102.997 100.905 100.994C104.945 98.9911 108.061 96.2359 110.256 92.7282V102.195H126.563V32.1642H110.256V41.6337ZM108.76 75.7472C107.762 78.4531 106.366 80.8078 104.572 82.8112C102.776 84.8161 100.606 86.4183 98.0637 87.6206C95.5202 88.823 92.7004 89.4238 89.6103 89.4238C86.5178 89.4238 83.7252 88.823 81.2324 87.6206C78.7388 86.4183 76.5949 84.8161 74.7998 82.8112C73.004 80.8078 71.6319 78.4531 70.6856 75.7472C69.7356 73.0421 69.2644 70.1868 69.2644 67.1821C69.2644 64.1758 69.7356 61.3205 70.6856 58.6154C71.6319 55.9102 73.004 53.5571 74.7998 51.5522C76.5949 49.5495 78.738 47.9451 81.2324 46.7427C83.7252 45.5404 86.5178 44.9396 89.6103 44.9396C92.7012 44.9396 95.5202 45.5404 98.0637 46.7427C100.606 47.9451 102.776 49.5487 104.572 51.5522C106.367 53.5571 107.762 55.9102 108.76 58.6154C109.756 61.3205 110.256 64.1758 110.256 67.1821C110.256 70.1868 109.756 73.0421 108.76 75.7472Z"
                        fill="currentColor" />
                    <path
                        d="M242.805 41.6337C240.611 38.1275 237.494 35.3731 233.455 33.3681C229.416 31.3647 225.351 30.3618 221.262 30.3618C215.974 30.3618 211.138 31.3389 206.75 33.2923C202.36 35.2456 198.597 37.928 195.455 41.3333C192.314 44.7401 189.869 48.6726 188.125 53.1293C186.378 57.589 185.507 62.274 185.507 67.1813C185.507 72.1925 186.378 76.8995 188.125 81.3069C189.868 85.7173 192.313 89.6241 195.455 93.0293C198.597 96.4361 202.361 99.1155 206.75 101.069C211.138 103.022 215.974 103.999 221.262 103.999C225.351 103.999 229.416 102.997 233.455 100.994C237.494 98.9911 240.611 96.2359 242.805 92.7282V102.195H259.112V32.1642H242.805V41.6337ZM241.31 75.7472C240.312 78.4531 238.916 80.8078 237.122 82.8112C235.326 84.8161 233.156 86.4183 230.614 87.6206C228.07 88.823 225.251 89.4238 222.16 89.4238C219.068 89.4238 216.275 88.823 213.782 87.6206C211.289 86.4183 209.145 84.8161 207.35 82.8112C205.554 80.8078 204.182 78.4531 203.236 75.7472C202.286 73.0421 201.814 70.1868 201.814 67.1821C201.814 64.1758 202.286 61.3205 203.236 58.6154C204.182 55.9102 205.554 53.5571 207.35 51.5522C209.145 49.5495 211.288 47.9451 213.782 46.7427C216.275 45.5404 219.068 44.9396 222.16 44.9396C225.251 44.9396 228.07 45.5404 230.614 46.7427C233.156 47.9451 235.326 49.5487 237.122 51.5522C238.917 53.5571 240.312 55.9102 241.31 58.6154C242.306 61.3205 242.806 64.1758 242.806 67.1821C242.805 70.1868 242.305 73.0421 241.31 75.7472Z"
                        fill="currentColor" />
                    <path d="M438 -3H421.694V102.197H438V-3Z" fill="currentColor" />
                    <path d="M139.43 102.197H155.735V48.2834H183.712V32.1665H139.43V102.197Z" fill="currentColor" />
                    <path
                        d="M324.49 32.1665L303.995 85.794L283.498 32.1665H266.983L293.748 102.197H314.242L341.006 32.1665H324.49Z"
                        fill="currentColor" />
                    <path
                        d="M376.571 30.3656C356.603 30.3656 340.797 46.8497 340.797 67.1828C340.797 89.6597 356.094 104 378.661 104C391.29 104 399.354 99.1488 409.206 88.5848L398.189 80.0226C398.183 80.031 389.874 90.9895 377.468 90.9895C363.048 90.9895 356.977 79.3111 356.977 73.269H411.075C413.917 50.1328 398.775 30.3656 376.571 30.3656ZM357.02 61.0967C357.145 59.7487 359.023 43.3761 376.442 43.3761C393.861 43.3761 395.978 59.7464 396.099 61.0967H357.02Z"
                        fill="currentColor" />
                </svg>

                {{-- Light Mode 12 SVG --}}
                <svg class="w-[448px] max-w-none relative -mt-[4.9rem] -ml-8 lg:ml-0 lg:-mt-[6.6rem] dark:hidden"
                    viewBox="0 0 440 376" fill="none" xmlns="http://www.w3.org/2000/svg">
                    <g
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M188.263 355.73L188.595 355.73C195.441 348.845 205.766 339.761 219.569 328.477C232.93 317.193 242.978 308.205 249.714 301.511C256.34 294.626 260.867 287.358 263.296 279.708C265.725 272.058 264.565 264.121 259.816 255.896C254.516 246.716 247.062 239.352 237.454 233.805C227.957 228.067 217.908 225.198 207.307 225.198C196.927 225.197 190.136 227.97 186.934 233.516C183.621 238.872 184.726 246.331 190.247 255.894L125.647 255.891C116.371 239.825 112.395 225.481 113.72 212.858C115.265 200.235 121.559 190.481 132.602 183.596C143.754 176.52 158.607 172.982 177.159 172.983C196.594 172.984 215.863 176.523 234.968 183.6C253.961 190.486 271.299 200.241 286.98 212.864C302.661 225.488 315.14 239.833 324.416 255.899C333.03 270.817 336.841 283.918 335.847 295.203C335.075 306.487 331.376 316.336 324.75 324.751C318.346 333.167 308.408 343.494 294.936 355.734L377.094 355.737L405.917 405.656L217.087 405.649L188.263 355.73Z"
                            fill="black" />
                        <path
                            d="M9.11884 226.339L-13.7396 226.338L-42.7286 176.132L43.0733 176.135L175.595 405.649L112.651 405.647L9.11884 226.339Z"
                            fill="black" />
                        <path
                            d="M188.263 355.73L188.595 355.73C195.441 348.845 205.766 339.761 219.569 328.477C232.93 317.193 242.978 308.205 249.714 301.511C256.34 294.626 260.867 287.358 263.296 279.708C265.725 272.058 264.565 264.121 259.816 255.896C254.516 246.716 247.062 239.352 237.454 233.805C227.957 228.067 217.908 225.198 207.307 225.198C196.927 225.197 190.136 227.97 186.934 233.516C183.621 238.872 184.726 246.331 190.247 255.894L125.647 255.891C116.371 239.825 112.395 225.481 113.72 212.858C115.265 200.235 121.559 190.481 132.602 183.596C143.754 176.52 158.607 172.982 177.159 172.983C196.594 172.984 215.863 176.523 234.968 183.6C253.961 190.486 271.299 200.241 286.98 212.864C302.661 225.488 315.14 239.833 324.416 255.899C333.03 270.817 336.841 283.918 335.847 295.203C335.075 306.487 331.376 316.336 324.75 324.751C318.346 333.167 308.408 343.494 294.936 355.734L377.094 355.737L405.917 405.656L217.087 405.649L188.263 355.73Z"
                            stroke="#1B1B18" stroke-width="1" />
                        <path
                            d="M9.11884 226.339L-13.7396 226.338L-42.7286 176.132L43.0733 176.135L175.595 405.649L112.651 405.647L9.11884 226.339Z"
                            stroke="#1B1B18" stroke-width="1" />
                        <path
                            d="M204.592 327.449L204.923 327.449C211.769 320.564 222.094 311.479 235.897 300.196C249.258 288.912 259.306 279.923 266.042 273.23C272.668 266.345 277.195 259.077 279.624 251.427C282.053 243.777 280.893 235.839 276.145 227.615C270.844 218.435 263.39 211.071 253.782 205.524C244.285 199.786 234.236 196.917 223.635 196.916C213.255 196.916 206.464 199.689 203.262 205.235C199.949 210.59 201.054 218.049 206.575 227.612L141.975 227.61C132.699 211.544 128.723 197.2 130.048 184.577C131.593 171.954 137.887 162.2 148.93 155.315C160.083 148.239 174.935 144.701 193.487 144.702C212.922 144.703 232.192 148.242 251.296 155.319C270.289 162.205 287.627 171.96 303.308 184.583C318.989 197.207 331.468 211.552 340.745 227.618C349.358 242.536 353.169 255.637 352.175 266.921C351.403 278.205 347.704 288.055 341.078 296.47C334.674 304.885 324.736 315.213 311.264 327.453L393.422 327.456L422.246 377.375L233.415 377.368L204.592 327.449Z"
                            fill="#F8B803" />
                        <path
                            d="M25.447 198.058L2.58852 198.057L-26.4005 147.851L59.4015 147.854L191.923 377.368L128.979 377.365L25.447 198.058Z"
                            fill="#F8B803" />
                        <path
                            d="M204.592 327.449L204.923 327.449C211.769 320.564 222.094 311.479 235.897 300.196C249.258 288.912 259.306 279.923 266.042 273.23C272.668 266.345 277.195 259.077 279.624 251.427C282.053 243.777 280.893 235.839 276.145 227.615C270.844 218.435 263.39 211.071 253.782 205.524C244.285 199.786 234.236 196.917 223.635 196.916C213.255 196.916 206.464 199.689 203.262 205.235C199.949 210.59 201.054 218.049 206.575 227.612L141.975 227.61C132.699 211.544 128.723 197.2 130.048 184.577C131.593 171.954 137.887 162.2 148.93 155.315C160.083 148.239 174.935 144.701 193.487 144.702C212.922 144.703 232.192 148.242 251.296 155.319C270.289 162.205 287.627 171.96 303.308 184.583C318.989 197.207 331.468 211.552 340.745 227.618C349.358 242.536 353.169 255.637 352.175 266.921C351.403 278.205 347.704 288.055 341.078 296.47C334.674 304.885 324.736 315.213 311.264 327.453L393.422 327.456L422.246 377.375L233.415 377.368L204.592 327.449Z"
                            stroke="#1B1B18" stroke-width="1" />
                        <path
                            d="M25.447 198.058L2.58852 198.057L-26.4005 147.851L59.4015 147.854L191.923 377.368L128.979 377.365L25.447 198.058Z"
                            stroke="#1B1B18" stroke-width="1" />
                    </g>
                    <g style="mix-blend-mode: hard-light"
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M217.342 305.363L217.673 305.363C224.519 298.478 234.844 289.393 248.647 278.11C262.008 266.826 272.056 257.837 278.792 251.144C285.418 244.259 289.945 236.991 292.374 229.341C294.803 221.691 293.643 213.753 288.895 205.529C283.594 196.349 276.14 188.985 266.532 183.438C257.035 177.7 246.986 174.831 236.385 174.83C226.005 174.83 219.214 177.603 216.012 183.149C212.699 188.504 213.804 195.963 219.325 205.527L154.725 205.524C145.449 189.458 141.473 175.114 142.798 162.491C144.343 149.868 150.637 140.114 161.68 133.229C172.833 126.153 187.685 122.615 206.237 122.616C225.672 122.617 244.942 126.156 264.046 133.233C283.039 140.119 300.377 149.874 316.058 162.497C331.739 175.121 344.218 189.466 353.495 205.532C362.108 220.45 365.919 233.551 364.925 244.835C364.153 256.12 360.454 265.969 353.828 274.384C347.424 282.799 337.486 293.127 324.014 305.367L406.172 305.37L434.996 355.289L246.165 355.282L217.342 305.363Z"
                            fill="#F0ACB8" />
                        <path
                            d="M38.197 175.972L15.3385 175.971L-13.6505 125.765L72.1515 125.768L204.673 355.282L141.729 355.279L38.197 175.972Z"
                            fill="#F0ACB8" />
                        <path
                            d="M217.342 305.363L217.673 305.363C224.519 298.478 234.844 289.393 248.647 278.11C262.008 266.826 272.056 257.837 278.792 251.144C285.418 244.259 289.945 236.991 292.374 229.341C294.803 221.691 293.643 213.753 288.895 205.529C283.594 196.349 276.14 188.985 266.532 183.438C257.035 177.7 246.986 174.831 236.385 174.83C226.005 174.83 219.214 177.603 216.012 183.149C212.699 188.504 213.804 195.963 219.325 205.527L154.725 205.524C145.449 189.458 141.473 175.114 142.798 162.491C144.343 149.868 150.637 140.114 161.68 133.229C172.833 126.153 187.685 122.615 206.237 122.616C225.672 122.617 244.942 126.156 264.046 133.233C283.039 140.119 300.377 149.874 316.058 162.497C331.739 175.121 344.218 189.466 353.495 205.532C362.108 220.45 365.919 233.551 364.925 244.835C364.153 256.12 360.454 265.969 353.828 274.384C347.424 282.799 337.486 293.127 324.014 305.367L406.172 305.37L434.996 355.289L246.165 355.282L217.342 305.363Z"
                            stroke="#1B1B18" stroke-width="1" />
                        <path
                            d="M38.197 175.972L15.3385 175.971L-13.6505 125.765L72.1515 125.768L204.673 355.282L141.729 355.279L38.197 175.972Z"
                            stroke="#1B1B18" stroke-width="1" />
                    </g>
                    <g style="mix-blend-mode: plus-darker"
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M230.951 281.792L231.282 281.793C238.128 274.907 248.453 265.823 262.256 254.539C275.617 243.256 285.666 234.267 292.402 227.573C299.027 220.688 303.554 213.421 305.983 205.771C308.412 198.12 307.253 190.183 302.504 181.959C297.203 172.778 289.749 165.415 280.142 159.868C270.645 154.13 260.596 151.26 249.995 151.26C239.615 151.26 232.823 154.033 229.621 159.579C226.309 164.934 227.413 172.393 232.935 181.956L168.335 181.954C159.058 165.888 155.082 151.543 156.407 138.92C157.953 126.298 164.247 116.544 175.289 109.659C186.442 102.583 201.294 99.045 219.846 99.0457C239.281 99.0464 258.551 102.585 277.655 109.663C296.649 116.549 313.986 126.303 329.667 138.927C345.349 151.551 357.827 165.895 367.104 181.961C375.718 196.88 379.528 209.981 378.535 221.265C377.762 232.549 374.063 242.399 367.438 250.814C361.033 259.229 351.095 269.557 337.624 281.796L419.782 281.8L448.605 331.719L259.774 331.712L230.951 281.792Z"
                            fill="#F3BEC7" />
                        <path
                            d="M51.8063 152.402L28.9479 152.401L-0.0411453 102.195L85.7608 102.198L218.282 331.711L155.339 331.709L51.8063 152.402Z"
                            fill="#F3BEC7" />
                        <path
                            d="M230.951 281.792L231.282 281.793C238.128 274.907 248.453 265.823 262.256 254.539C275.617 243.256 285.666 234.267 292.402 227.573C299.027 220.688 303.554 213.421 305.983 205.771C308.412 198.12 307.253 190.183 302.504 181.959C297.203 172.778 289.749 165.415 280.142 159.868C270.645 154.13 260.596 151.26 249.995 151.26C239.615 151.26 232.823 154.033 229.621 159.579C226.309 164.934 227.413 172.393 232.935 181.956L168.335 181.954C159.058 165.888 155.082 151.543 156.407 138.92C157.953 126.298 164.247 116.544 175.289 109.659C186.442 102.583 201.294 99.045 219.846 99.0457C239.281 99.0464 258.551 102.585 277.655 109.663C296.649 116.549 313.986 126.303 329.667 138.927C345.349 151.551 357.827 165.895 367.104 181.961C375.718 196.88 379.528 209.981 378.535 221.265C377.762 232.549 374.063 242.399 367.438 250.814C361.033 259.229 351.095 269.557 337.624 281.796L419.782 281.8L448.605 331.719L259.774 331.712L230.951 281.792Z"
                            stroke="#1B1B18" stroke-width="1" />
                        <path
                            d="M51.8063 152.402L28.9479 152.401L-0.0411453 102.195L85.7608 102.198L218.282 331.711L155.339 331.709L51.8063 152.402Z"
                            stroke="#1B1B18" stroke-width="1" />
                    </g>
                    <g
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M188.467 355.363L188.798 355.363C195.644 348.478 205.969 339.393 219.772 328.11C233.133 316.826 243.181 307.837 249.917 301.144C253.696 297.217 256.792 293.166 259.205 288.991C261.024 285.845 262.455 282.628 263.499 279.341C265.928 271.691 264.768 263.753 260.02 255.529C254.719 246.349 247.265 238.985 237.657 233.438C228.16 227.7 218.111 224.831 207.51 224.83C197.13 224.83 190.339 227.603 187.137 233.149C183.824 238.504 184.929 245.963 190.45 255.527L125.851 255.524C116.574 239.458 112.598 225.114 113.923 212.491C114.615 206.836 116.261 201.756 118.859 197.253C122.061 191.704 126.709 187.03 132.805 183.229C143.958 176.153 158.81 172.615 177.362 172.616C196.797 172.617 216.067 176.156 235.171 183.233C254.164 190.119 271.502 199.874 287.183 212.497C302.864 225.121 315.343 239.466 324.62 255.532C333.233 270.45 337.044 283.551 336.05 294.835C335.46 303.459 333.16 311.245 329.151 318.194C327.915 320.337 326.515 322.4 324.953 324.384C318.549 332.799 308.611 343.127 295.139 355.367L377.297 355.37L406.121 405.289L217.29 405.282L188.467 355.363Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M9.32197 225.972L-13.5365 225.971L-42.5255 175.765L43.2765 175.768L175.798 405.282L112.854 405.279L9.32197 225.972Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M345.247 111.915C329.566 99.2919 312.229 89.5371 293.235 82.6512L235.167 183.228C254.161 190.114 271.498 199.869 287.179 212.492L345.247 111.915Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M382.686 154.964C373.41 138.898 360.931 124.553 345.25 111.93L287.182 212.506C302.863 225.13 315.342 239.475 324.618 255.541L382.686 154.964Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M293.243 82.6472C274.139 75.57 254.869 72.031 235.434 72.0303L177.366 172.607C196.801 172.608 216.071 176.147 235.175 183.224L293.243 82.6472Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M394.118 194.257C395.112 182.973 391.301 169.872 382.688 154.953L324.619 255.53C333.233 270.448 337.044 283.55 336.05 294.834L394.118 194.257Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M235.432 72.0311C216.88 72.0304 202.027 75.5681 190.875 82.6442L132.806 183.221C143.959 176.145 158.812 172.607 177.363 172.608L235.432 72.0311Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M265.59 124.25C276.191 124.251 286.24 127.12 295.737 132.858L237.669 233.435C228.172 227.697 218.123 224.828 207.522 224.827L265.59 124.25Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M295.719 132.859C305.326 138.406 312.78 145.77 318.081 154.95L260.013 255.527C254.712 246.347 247.258 238.983 237.651 233.436L295.719 132.859Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M387.218 217.608C391.227 210.66 393.527 202.874 394.117 194.25L336.049 294.827C335.459 303.451 333.159 311.237 329.15 318.185L387.218 217.608Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M245.211 132.577C248.413 127.03 255.204 124.257 265.584 124.258L207.516 224.835C197.136 224.834 190.345 227.607 187.143 233.154L245.211 132.577Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M318.094 154.945C322.842 163.17 324.002 171.107 321.573 178.757L263.505 279.334C265.934 271.684 264.774 263.746 260.026 255.522L318.094 154.945Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M176.925 96.6737C180.127 91.1249 184.776 86.4503 190.871 82.6499L132.803 183.227C126.708 187.027 122.059 191.702 118.857 197.25L176.925 96.6737Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M387.226 217.606C385.989 219.749 384.59 221.813 383.028 223.797L324.96 324.373C326.522 322.39 327.921 320.326 329.157 318.183L387.226 217.606Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M317.269 188.408C319.087 185.262 320.519 182.045 321.562 178.758L263.494 279.335C262.451 282.622 261.019 285.839 259.201 288.985L317.269 188.408Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M245.208 132.573C241.895 137.928 243 145.387 248.522 154.95L190.454 255.527C184.932 245.964 183.827 238.505 187.14 233.15L245.208 132.573Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M176.93 96.6719C174.331 101.175 172.686 106.255 171.993 111.91L113.925 212.487C114.618 206.831 116.263 201.752 118.862 197.249L176.93 96.6719Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M317.266 188.413C314.853 192.589 311.757 196.64 307.978 200.566L249.91 301.143C253.689 297.216 256.785 293.166 259.198 288.99L317.266 188.413Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M464.198 304.708L435.375 254.789L377.307 355.366L406.13 405.285L464.198 304.708Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M353.209 254.787C366.68 242.548 376.618 232.22 383.023 223.805L324.955 324.382C318.55 332.797 308.612 343.124 295.141 355.364L353.209 254.787Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M435.37 254.787L353.212 254.784L295.144 355.361L377.302 355.364L435.37 254.787Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M183.921 154.947L248.521 154.95L190.453 255.527L125.853 255.524L183.921 154.947Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M171.992 111.914C170.668 124.537 174.643 138.881 183.92 154.947L125.852 255.524C116.575 239.458 112.599 225.114 113.924 212.491L171.992 111.914Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M307.987 200.562C301.251 207.256 291.203 216.244 277.842 227.528L219.774 328.105C233.135 316.821 243.183 307.832 249.919 301.139L307.987 200.562Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M15.5469 75.1797L44.5359 125.386L-13.5321 225.963L-42.5212 175.756L15.5469 75.1797Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M277.836 227.536C264.033 238.82 253.708 247.904 246.862 254.789L188.794 355.366C195.64 348.481 205.965 339.397 219.768 328.113L277.836 227.536Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M275.358 304.706L464.189 304.713L406.12 405.29L217.29 405.283L275.358 304.706Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M44.5279 125.39L67.3864 125.39L9.31834 225.967L-13.5401 225.966L44.5279 125.39Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M101.341 75.1911L233.863 304.705L175.795 405.282L43.2733 175.768L101.341 75.1911ZM15.5431 75.19L-42.525 175.767L43.277 175.77L101.345 75.1932L15.5431 75.19Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M246.866 254.784L246.534 254.784L188.466 355.361L188.798 355.361L246.866 254.784Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M246.539 254.781L275.362 304.701L217.294 405.277L188.471 355.358L246.539 254.781Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M67.3906 125.391L170.923 304.698L112.855 405.275L9.32257 225.967L67.3906 125.391Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M170.921 304.699L233.865 304.701L175.797 405.278L112.853 405.276L170.921 304.699Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="bevel" />
                    </g>
                    <g style="mix-blend-mode: hard-light"
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M246.544 254.79L246.875 254.79C253.722 247.905 264.046 238.82 277.849 227.537C291.21 216.253 301.259 207.264 307.995 200.57C314.62 193.685 319.147 186.418 321.577 178.768C324.006 171.117 322.846 163.18 318.097 154.956C312.796 145.775 305.342 138.412 295.735 132.865C286.238 127.127 276.189 124.258 265.588 124.257C255.208 124.257 248.416 127.03 245.214 132.576C241.902 137.931 243.006 145.39 248.528 154.953L183.928 154.951C174.652 138.885 170.676 124.541 172 111.918C173.546 99.2946 179.84 89.5408 190.882 82.6559C202.035 75.5798 216.887 72.0421 235.439 72.0428C254.874 72.0435 274.144 75.5825 293.248 82.6598C312.242 89.5457 329.579 99.3005 345.261 111.924C360.942 124.548 373.421 138.892 382.697 154.958C391.311 169.877 395.121 182.978 394.128 194.262C393.355 205.546 389.656 215.396 383.031 223.811C376.627 232.226 366.688 242.554 353.217 254.794L435.375 254.797L464.198 304.716L275.367 304.709L246.544 254.79Z"
                            fill="#F0ACB8" />
                        <path
                            d="M246.544 254.79L246.875 254.79C253.722 247.905 264.046 238.82 277.849 227.537C291.21 216.253 301.259 207.264 307.995 200.57C314.62 193.685 319.147 186.418 321.577 178.768C324.006 171.117 322.846 163.18 318.097 154.956C312.796 145.775 305.342 138.412 295.735 132.865C286.238 127.127 276.189 124.258 265.588 124.257C255.208 124.257 248.416 127.03 245.214 132.576C241.902 137.931 243.006 145.39 248.528 154.953L183.928 154.951C174.652 138.885 170.676 124.541 172 111.918C173.546 99.2946 179.84 89.5408 190.882 82.6559C202.035 75.5798 216.887 72.0421 235.439 72.0428C254.874 72.0435 274.144 75.5825 293.248 82.6598C312.242 89.5457 329.579 99.3005 345.261 111.924C360.942 124.548 373.421 138.892 382.697 154.958C391.311 169.877 395.121 182.978 394.128 194.262C393.355 205.546 389.656 215.396 383.031 223.811C376.627 232.226 366.688 242.554 353.217 254.794L435.375 254.797L464.198 304.716L275.367 304.709L246.544 254.79Z"
                            stroke="#1B1B18" stroke-width="1" stroke-linejoin="round" />
                    </g>
                    <g style="mix-blend-mode: hard-light"
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M67.41 125.402L44.5515 125.401L15.5625 75.1953L101.364 75.1985L233.886 304.712L170.942 304.71L67.41 125.402Z"
                            fill="#F0ACB8" />
                        <path
                            d="M67.41 125.402L44.5515 125.401L15.5625 75.1953L101.364 75.1985L233.886 304.712L170.942 304.71L67.41 125.402Z"
                            stroke="#1B1B18" stroke-width="1" />
                    </g>
                </svg>

                {{-- Dark Mode 12 SVG --}}
                <svg class="w-[448px] max-w-none relative -mt-[4.9rem] -ml-8 lg:ml-0 lg:-mt-[6.6rem] hidden dark:block"
                    viewBox="0 0 440 376" fill="none" xmlns="http://www.w3.org/2000/svg">
                    <g
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M188.263 355.73L188.595 355.73C195.441 348.845 205.766 339.761 219.569 328.477C232.93 317.193 242.978 308.205 249.714 301.511C256.34 294.626 260.867 287.358 263.296 279.708C265.725 272.058 264.565 264.121 259.816 255.896C254.516 246.716 247.062 239.352 237.454 233.805C227.957 228.067 217.908 225.198 207.307 225.198C196.927 225.197 190.136 227.97 186.934 233.516C183.621 238.872 184.726 246.331 190.247 255.894L125.647 255.891C116.371 239.825 112.395 225.481 113.72 212.858C115.265 200.235 121.559 190.481 132.602 183.596C143.754 176.52 158.607 172.982 177.159 172.983C196.594 172.984 215.863 176.523 234.968 183.6C253.961 190.486 271.299 200.241 286.98 212.864C302.661 225.488 315.14 239.833 324.416 255.899C333.03 270.817 336.841 283.918 335.847 295.203C335.075 306.487 331.376 316.336 324.75 324.751C318.346 333.167 308.408 343.494 294.936 355.734L377.094 355.737L405.917 405.656L217.087 405.649L188.263 355.73Z"
                            fill="black" />
                        <path
                            d="M9.11884 226.339L-13.7396 226.338L-42.7286 176.132L43.0733 176.135L175.595 405.649L112.651 405.647L9.11884 226.339Z"
                            fill="black" />
                        <path
                            d="M188.263 355.73L188.595 355.73C195.441 348.845 205.766 339.761 219.569 328.477C232.93 317.193 242.978 308.205 249.714 301.511C256.34 294.626 260.867 287.358 263.296 279.708C265.725 272.058 264.565 264.121 259.816 255.896C254.516 246.716 247.062 239.352 237.454 233.805C227.957 228.067 217.908 225.198 207.307 225.198C196.927 225.197 190.136 227.97 186.934 233.516C183.621 238.872 184.726 246.331 190.247 255.894L125.647 255.891C116.371 239.825 112.395 225.481 113.72 212.858C115.265 200.235 121.559 190.481 132.602 183.596C143.754 176.52 158.607 172.982 177.159 172.983C196.594 172.984 215.863 176.523 234.968 183.6C253.961 190.486 271.299 200.241 286.98 212.864C302.661 225.488 315.14 239.833 324.416 255.899C333.03 270.817 336.841 283.918 335.847 295.203C335.075 306.487 331.376 316.336 324.75 324.751C318.346 333.167 308.408 343.494 294.936 355.734L377.094 355.737L405.917 405.656L217.087 405.649L188.263 355.73Z"
                            stroke="#FF750F" stroke-width="1" />
                        <path
                            d="M9.11884 226.339L-13.7396 226.338L-42.7286 176.132L43.0733 176.135L175.595 405.649L112.651 405.647L9.11884 226.339Z"
                            stroke="#FF750F" stroke-width="1" />
                        <path
                            d="M204.592 327.449L204.923 327.449C211.769 320.564 222.094 311.479 235.897 300.196C249.258 288.912 259.306 279.923 266.042 273.23C272.668 266.345 277.195 259.077 279.624 251.427C282.053 243.777 280.893 235.839 276.145 227.615C270.844 218.435 263.39 211.071 253.782 205.524C244.285 199.786 234.236 196.917 223.635 196.916C213.255 196.916 206.464 199.689 203.262 205.235C199.949 210.59 201.054 218.049 206.575 227.612L141.975 227.61C132.699 211.544 128.723 197.2 130.048 184.577C131.593 171.954 137.887 162.2 148.93 155.315C160.083 148.239 174.935 144.701 193.487 144.702C212.922 144.703 232.192 148.242 251.296 155.319C270.289 162.205 287.627 171.96 303.308 184.583C318.989 197.207 331.468 211.552 340.745 227.618C349.358 242.536 353.169 255.637 352.175 266.921C351.403 278.205 347.704 288.055 341.078 296.47C334.674 304.885 324.736 315.213 311.264 327.453L393.422 327.456L422.246 377.375L233.415 377.368L204.592 327.449Z"
                            fill="#391800" />
                        <path
                            d="M25.447 198.058L2.58852 198.057L-26.4005 147.851L59.4015 147.854L191.923 377.368L128.979 377.365L25.447 198.058Z"
                            fill="#391800" />
                        <path
                            d="M204.592 327.449L204.923 327.449C211.769 320.564 222.094 311.479 235.897 300.196C249.258 288.912 259.306 279.923 266.042 273.23C272.668 266.345 277.195 259.077 279.624 251.427C282.053 243.777 280.893 235.839 276.145 227.615C270.844 218.435 263.39 211.071 253.782 205.524C244.285 199.786 234.236 196.917 223.635 196.916C213.255 196.916 206.464 199.689 203.262 205.235C199.949 210.59 201.054 218.049 206.575 227.612L141.975 227.61C132.699 211.544 128.723 197.2 130.048 184.577C131.593 171.954 137.887 162.2 148.93 155.315C160.083 148.239 174.935 144.701 193.487 144.702C212.922 144.703 232.192 148.242 251.296 155.319C270.289 162.205 287.627 171.96 303.308 184.583C318.989 197.207 331.468 211.552 340.745 227.618C349.358 242.536 353.169 255.637 352.175 266.921C351.403 278.205 347.704 288.055 341.078 296.47C334.674 304.885 324.736 315.213 311.264 327.453L393.422 327.456L422.246 377.375L233.415 377.368L204.592 327.449Z"
                            stroke="#FF750F" stroke-width="1" />
                        <path
                            d="M25.447 198.058L2.58852 198.057L-26.4005 147.851L59.4015 147.854L191.923 377.368L128.979 377.365L25.447 198.058Z"
                            stroke="#FF750F" stroke-width="1" />
                    </g>
                    <g class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4"
                        style="mix-blend-mode:hard-light">
                        <path
                            d="M217.342 305.363L217.673 305.363C224.519 298.478 234.844 289.393 248.647 278.11C262.008 266.826 272.056 257.837 278.792 251.144C285.418 244.259 289.945 236.991 292.374 229.341C294.803 221.691 293.643 213.753 288.895 205.529C283.594 196.349 276.14 188.985 266.532 183.438C257.035 177.7 246.986 174.831 236.385 174.83C226.005 174.83 219.214 177.603 216.012 183.149C212.699 188.504 213.804 195.963 219.325 205.527L154.725 205.524C145.449 189.458 141.473 175.114 142.798 162.491C144.343 149.868 150.637 140.114 161.68 133.229C172.833 126.153 187.685 122.615 206.237 122.616C225.672 122.617 244.942 126.156 264.046 133.233C283.039 140.119 300.377 149.874 316.058 162.497C331.739 175.121 344.218 189.466 353.495 205.532C362.108 220.45 365.919 233.551 364.925 244.835C364.153 256.12 360.454 265.969 353.828 274.384C347.424 282.799 337.486 293.127 324.014 305.367L406.172 305.37L434.996 355.289L246.165 355.282L217.342 305.363Z"
                            fill="#733000" />
                        <path
                            d="M38.197 175.972L15.3385 175.971L-13.6505 125.765L72.1515 125.768L204.673 355.282L141.729 355.279L38.197 175.972Z"
                            fill="#733000" />
                        <path
                            d="M217.342 305.363L217.673 305.363C224.519 298.478 234.844 289.393 248.647 278.11C262.008 266.826 272.056 257.837 278.792 251.144C285.418 244.259 289.945 236.991 292.374 229.341C294.803 221.691 293.643 213.753 288.895 205.529C283.594 196.349 276.14 188.985 266.532 183.438C257.035 177.7 246.986 174.831 236.385 174.83C226.005 174.83 219.214 177.603 216.012 183.149C212.699 188.504 213.804 195.963 219.325 205.527L154.725 205.524C145.449 189.458 141.473 175.114 142.798 162.491C144.343 149.868 150.637 140.114 161.68 133.229C172.833 126.153 187.685 122.615 206.237 122.616C225.672 122.617 244.942 126.156 264.046 133.233C283.039 140.119 300.377 149.874 316.058 162.497C331.739 175.121 344.218 189.466 353.495 205.532C362.108 220.45 365.919 233.551 364.925 244.835C364.153 256.12 360.454 265.969 353.828 274.384C347.424 282.799 337.486 293.127 324.014 305.367L406.172 305.37L434.996 355.289L246.165 355.282L217.342 305.363Z"
                            stroke="#FF750F" stroke-width="1" />
                        <path
                            d="M38.197 175.972L15.3385 175.971L-13.6505 125.765L72.1515 125.768L204.673 355.282L141.729 355.279L38.197 175.972Z"
                            stroke="#FF750F" stroke-width="1" />
                    </g>
                    <g
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M217.342 305.363L217.673 305.363C224.519 298.478 234.844 289.393 248.647 278.11C262.008 266.826 272.056 257.837 278.792 251.144C285.418 244.259 289.945 236.991 292.374 229.341C294.803 221.691 293.643 213.753 288.895 205.529C283.594 196.349 276.14 188.985 266.532 183.438C257.035 177.7 246.986 174.831 236.385 174.83C226.005 174.83 219.214 177.603 216.012 183.149C212.699 188.504 213.804 195.963 219.325 205.527L154.726 205.524C145.449 189.458 141.473 175.114 142.798 162.491C144.343 149.868 150.637 140.114 161.68 133.229C172.833 126.153 187.685 122.615 206.237 122.616C225.672 122.617 244.942 126.156 264.046 133.233C283.039 140.119 300.377 149.874 316.058 162.497C331.739 175.121 344.218 189.466 353.495 205.532C362.108 220.45 365.919 233.551 364.925 244.835C364.153 256.12 360.454 265.969 353.828 274.384C347.424 282.799 337.486 293.127 324.014 305.367L406.172 305.37L434.996 355.289L246.165 355.282L217.342 305.363Z"
                            stroke="#FF750F" stroke-width="1" />
                        <path
                            d="M38.197 175.972L15.3385 175.971L-13.6505 125.765L72.1515 125.768L204.673 355.282L141.729 355.279L38.197 175.972Z"
                            stroke="#FF750F" stroke-width="1" />
                    </g>
                    <g
                        class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4">
                        <path
                            d="M188.467 355.363L188.798 355.363C195.644 348.478 205.969 339.393 219.772 328.11C233.133 316.826 243.181 307.837 249.917 301.144C253.696 297.217 256.792 293.166 259.205 288.991C261.024 285.845 262.455 282.628 263.499 279.341C265.928 271.691 264.768 263.753 260.02 255.529C254.719 246.349 247.265 238.985 237.657 233.438C228.16 227.7 218.111 224.831 207.51 224.83C197.13 224.83 190.339 227.603 187.137 233.149C183.824 238.504 184.929 245.963 190.45 255.527L125.851 255.524C116.574 239.458 112.598 225.114 113.923 212.491C114.615 206.836 116.261 201.756 118.859 197.253C122.061 191.704 126.709 187.03 132.805 183.229C143.958 176.153 158.81 172.615 177.362 172.616C196.797 172.617 216.067 176.156 235.171 183.233C254.164 190.119 271.502 199.874 287.183 212.497C302.864 225.121 315.343 239.466 324.62 255.532C333.233 270.45 337.044 283.551 336.05 294.835C335.46 303.459 333.16 311.245 329.151 318.194C327.915 320.337 326.515 322.4 324.953 324.384C318.549 332.799 308.611 343.127 295.139 355.367L377.297 355.37L406.121 405.289L217.29 405.282L188.467 355.363Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M9.32197 225.972L-13.5365 225.971L-42.5255 175.765L43.2765 175.768L175.798 405.282L112.854 405.279L9.32197 225.972Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M345.247 111.915C329.566 99.2919 312.229 89.5371 293.235 82.6512L235.167 183.228C254.161 190.114 271.498 199.869 287.179 212.492L345.247 111.915Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M382.686 154.964C373.41 138.898 360.931 124.553 345.25 111.93L287.182 212.506C302.863 225.13 315.342 239.475 324.618 255.541L382.686 154.964Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M293.243 82.6472C274.139 75.57 254.869 72.031 235.434 72.0303L177.366 172.607C196.801 172.608 216.071 176.147 235.175 183.224L293.243 82.6472Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M394.118 194.257C395.112 182.973 391.301 169.872 382.688 154.953L324.619 255.53C333.233 270.448 337.044 283.55 336.05 294.834L394.118 194.257Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M235.432 72.0311C216.88 72.0304 202.027 75.5681 190.875 82.6442L132.806 183.221C143.959 176.145 158.812 172.607 177.363 172.608L235.432 72.0311Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M265.59 124.25C276.191 124.251 286.24 127.12 295.737 132.858L237.669 233.435C228.172 227.697 218.123 224.828 207.522 224.827L265.59 124.25Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M295.719 132.859C305.326 138.406 312.78 145.77 318.081 154.95L260.013 255.527C254.712 246.347 247.258 238.983 237.651 233.436L295.719 132.859Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M387.218 217.608C391.227 210.66 393.527 202.874 394.117 194.25L336.049 294.827C335.459 303.451 333.159 311.237 329.15 318.185L387.218 217.608Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M245.211 132.577C248.413 127.03 255.204 124.257 265.584 124.258L207.516 224.835C197.136 224.834 190.345 227.607 187.143 233.154L245.211 132.577Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M318.094 154.945C322.842 163.17 324.002 171.107 321.573 178.757L263.505 279.334C265.934 271.684 264.774 263.746 260.026 255.522L318.094 154.945Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M176.925 96.6737C180.127 91.1249 184.776 86.4503 190.871 82.6499L132.803 183.227C126.708 187.027 122.059 191.702 118.857 197.25L176.925 96.6737Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M387.226 217.606C385.989 219.749 384.59 221.813 383.028 223.797L324.96 324.373C326.522 322.39 327.921 320.326 329.157 318.183L387.226 217.606Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M317.269 188.408C319.087 185.262 320.519 182.045 321.562 178.758L263.494 279.335C262.451 282.622 261.019 285.839 259.201 288.985L317.269 188.408Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M245.208 132.573C241.895 137.928 243 145.387 248.522 154.95L190.454 255.527C184.932 245.964 183.827 238.505 187.14 233.15L245.208 132.573Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M176.93 96.6719C174.331 101.175 172.686 106.255 171.993 111.91L113.925 212.487C114.618 206.831 116.263 201.752 118.862 197.249L176.93 96.6719Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M317.266 188.413C314.853 192.589 311.757 196.64 307.978 200.566L249.91 301.143C253.689 297.216 256.785 293.166 259.198 288.99L317.266 188.413Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M464.198 304.708L435.375 254.789L377.307 355.366L406.13 405.285L464.198 304.708Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M353.209 254.787C366.68 242.548 376.618 232.22 383.023 223.805L324.955 324.382C318.55 332.797 308.612 343.124 295.141 355.364L353.209 254.787Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M435.37 254.787L353.212 254.784L295.144 355.361L377.302 355.364L435.37 254.787Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M183.921 154.947L248.521 154.95L190.453 255.527L125.853 255.524L183.921 154.947Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M171.992 111.914C170.668 124.537 174.643 138.881 183.92 154.947L125.852 255.524C116.575 239.458 112.599 225.114 113.924 212.491L171.992 111.914Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M307.987 200.562C301.251 207.256 291.203 216.244 277.842 227.528L219.774 328.105C233.135 316.821 243.183 307.832 249.919 301.139L307.987 200.562Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M15.5469 75.1797L44.5359 125.386L-13.5321 225.963L-42.5212 175.756L15.5469 75.1797Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M277.836 227.536C264.033 238.82 253.708 247.904 246.862 254.789L188.794 355.366C195.64 348.481 205.965 339.397 219.768 328.113L277.836 227.536Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M275.358 304.706L464.189 304.713L406.12 405.29L217.29 405.283L275.358 304.706Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M44.5279 125.39L67.3864 125.39L9.31834 225.967L-13.5401 225.966L44.5279 125.39Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path
                            d="M101.341 75.1911L233.863 304.705L175.795 405.282L43.2733 175.768L101.341 75.1911ZM15.5431 75.19L-42.525 175.767L43.277 175.77L101.345 75.1932L15.5431 75.19Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M246.866 254.784L246.534 254.784L188.466 355.361L188.798 355.361L246.866 254.784Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M246.539 254.781L275.362 304.701L217.294 405.277L188.471 355.358L246.539 254.781Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M67.3906 125.391L170.923 304.698L112.855 405.275L9.32257 225.967L67.3906 125.391Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                        <path d="M170.921 304.699L233.865 304.701L175.797 405.278L112.853 405.276L170.921 304.699Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="bevel" />
                    </g>
                    <g class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4"
                        style="mix-blend-mode:hard-light">
                        <path
                            d="M246.544 254.79L246.875 254.79C253.722 247.905 264.046 238.82 277.849 227.537C291.21 216.253 301.259 207.264 307.995 200.57C314.62 193.685 319.147 186.418 321.577 178.768C324.006 171.117 322.846 163.18 318.097 154.956C312.796 145.775 305.342 138.412 295.735 132.865C286.238 127.127 276.189 124.258 265.588 124.257C255.208 124.257 248.416 127.03 245.214 132.576C241.902 137.931 243.006 145.39 248.528 154.953L183.928 154.951C174.652 138.885 170.676 124.541 172 111.918C173.546 99.2946 179.84 89.5408 190.882 82.6559C202.035 75.5798 216.887 72.0421 235.439 72.0428C254.874 72.0435 274.144 75.5825 293.248 82.6598C312.242 89.5457 329.579 99.3005 345.261 111.924C360.942 124.548 373.421 138.892 382.697 154.958C391.311 169.877 395.121 182.978 394.128 194.262C393.355 205.546 389.656 215.396 383.031 223.811C376.627 232.226 366.688 242.554 353.217 254.794L435.375 254.797L464.198 304.716L275.367 304.709L246.544 254.79Z"
                            fill="#4B0600" />
                        <path
                            d="M246.544 254.79L246.875 254.79C253.722 247.905 264.046 238.82 277.849 227.537C291.21 216.253 301.259 207.264 307.995 200.57C314.62 193.685 319.147 186.418 321.577 178.768C324.006 171.117 322.846 163.18 318.097 154.956C312.796 145.775 305.342 138.412 295.735 132.865C286.238 127.127 276.189 124.258 265.588 124.257C255.208 124.257 248.416 127.03 245.214 132.576C241.902 137.931 243.006 145.39 248.528 154.953L183.928 154.951C174.652 138.885 170.676 124.541 172 111.918C173.546 99.2946 179.84 89.5408 190.882 82.6559C202.035 75.5798 216.887 72.0421 235.439 72.0428C254.874 72.0435 274.144 75.5825 293.248 82.6598C312.242 89.5457 329.579 99.3005 345.261 111.924C360.942 124.548 373.421 138.892 382.697 154.958C391.311 169.877 395.121 182.978 394.128 194.262C393.355 205.546 389.656 215.396 383.031 223.811C376.627 232.226 366.688 242.554 353.217 254.794L435.375 254.797L464.198 304.716L275.367 304.709L246.544 254.79Z"
                            stroke="#FF750F" stroke-width="1" stroke-linejoin="round" />
                    </g>
                    <g class="transition-all delay-300 translate-y-0 opacity-100 duration-750 starting:opacity-0 starting:translate-y-4"
                        style="mix-blend-mode:hard-light">
                        <path
                            d="M67.41 125.402L44.5515 125.401L15.5625 75.1953L101.364 75.1985L233.886 304.712L170.942 304.71L67.41 125.402Z"
                            fill="#4B0600" />
                        <path
                            d="M67.41 125.402L44.5515 125.401L15.5625 75.1953L101.364 75.1985L233.886 304.712L170.942 304.71L67.41 125.402Z"
                            stroke="#FF750F" stroke-width="1" />
                    </g>
                </svg>
                <div
                    class="absolute inset-0 rounded-t-lg lg:rounded-t-none lg:rounded-r-lg shadow-[inset_0px_0px_0px_1px_rgba(26,26,0,0.16)] dark:shadow-[inset_0px_0px_0px_1px_#fffaed2d]">
                </div>
            </div>
        </main>
    </div>

    @if (Route::has('login'))
        <div class="h-14.5 hidden lg:block"></div>
    @endif
</body>

</html>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/auth/reset-password.blade.php ---
<x-guest-layout>
    <form method="POST" action="{{ route('password.store') }}">
        @csrf

        <!-- Password Reset Token -->
        <input type="hidden" name="token" value="{{ $request->route('token') }}">

        <!-- Email Address -->
        <div>
            <x-input-label for="email" :value="__('Email')" />
            <x-text-input id="email" class="block mt-1 w-full" type="email" name="email" :value="old('email', $request->email)" required autofocus autocomplete="username" />
            <x-input-error :messages="$errors->get('email')" class="mt-2" />
        </div>

        <!-- Password -->
        <div class="mt-4">
            <x-input-label for="password" :value="__('Password')" />
            <x-text-input id="password" class="block mt-1 w-full" type="password" name="password" required autocomplete="new-password" />
            <x-input-error :messages="$errors->get('password')" class="mt-2" />
        </div>

        <!-- Confirm Password -->
        <div class="mt-4">
            <x-input-label for="password_confirmation" :value="__('Confirm Password')" />

            <x-text-input id="password_confirmation" class="block mt-1 w-full"
                                type="password"
                                name="password_confirmation" required autocomplete="new-password" />

            <x-input-error :messages="$errors->get('password_confirmation')" class="mt-2" />
        </div>

        <div class="flex items-center justify-end mt-4">
            <x-primary-button>
                {{ __('Reset Password') }}
            </x-primary-button>
        </div>
    </form>
</x-guest-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/auth/login.blade.ori.php ---
<x-guest-layout>
    <!-- Session Status -->
    <x-auth-session-status class="mb-4" :status="session('status')" />

    <form method="POST" action="{{ route('login') }}">
        @csrf

        <!-- Login ID -->
        <div>
            <x-input-label for="login_id" :value="__('Login ID')" />

            <x-text-input id="login_id" class="block mt-1 w-full" type="text" name="login_id" :value="old('login_id')" required
                autofocus autocomplete="username" />

            <x-input-error :messages="$errors->get('login_id')" class="mt-2" />
        </div>

        <!-- Password -->
        <div class="mt-4">
            <x-input-label for="password" :value="__('Password')" />

            <x-text-input id="password" class="block mt-1 w-full" type="password" name="password" required
                autocomplete="current-password" />

            <x-input-error :messages="$errors->get('password')" class="mt-2" />
        </div>

        <!-- Remember Me -->
        <div class="block mt-4">
            <label for="remember_me" class="inline-flex items-center">
                <input id="remember_me" type="checkbox"
                    class="rounded border-gray-300 text-indigo-600 shadow-sm focus:ring-indigo-500" name="remember">
                <span class="ms-2 text-sm text-gray-600">{{ __('Remember me') }}</span>
            </label>
        </div>

        <div class="flex items-center justify-end mt-4">
            @if (Route::has('password.request'))
                <a class="underline text-sm text-gray-600 hover:text-gray-900 rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
                    href="{{ route('password.request') }}">
                    {{ __('Forgot your password?') }}
                </a>
            @endif

            <x-primary-button class="ms-3">
                {{ __('Log in') }}
            </x-primary-button>
        </div>
    </form>
</x-guest-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/auth/forgot-password.blade.php ---
<x-guest-layout>
    <div class="mb-4 text-sm text-gray-600">
        {{ __('Forgot your password? No problem. Just let us know your email address and we will email you a password reset link that will allow you to choose a new one.') }}
    </div>

    <!-- Session Status -->
    <x-auth-session-status class="mb-4" :status="session('status')" />

    <form method="POST" action="{{ route('password.email') }}">
        @csrf

        <!-- Email Address -->
        <div>
            <x-input-label for="email" :value="__('Email')" />
            <x-text-input id="email" class="block mt-1 w-full" type="email" name="email" :value="old('email')" required autofocus />
            <x-input-error :messages="$errors->get('email')" class="mt-2" />
        </div>

        <div class="flex items-center justify-end mt-4">
            <x-primary-button>
                {{ __('Email Password Reset Link') }}
            </x-primary-button>
        </div>
    </form>
</x-guest-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/auth/login.blade.php ---
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="csrf-token" content="{{ csrf_token() }}">

    <title>{{ config('app.name', 'Laravel') }}</title>

    <script src="https://cdn.tailwindcss.com"></script>
    <script>
        tailwind.config = {
            theme: {
                extend: {
                    colors: {
                        maxtop: {
                            DEFAULT: '#597E38', /* 你的绿色 */
                            hover: '#46632c',
                        }
                    },
                    boxShadow: {
                        'soft': '0 20px 40px -15px rgba(0, 0, 0, 0.15)',
                    }
                }
            }
        }
    </script>
</head>
<body class="font-sans antialiased">
    <div class="min-h-screen bg-gradient-to-br from-[#597E38] to-[#364e22] flex flex-col justify-center items-center p-6">
        
        <div class="mb-8 flex flex-col items-center animate-pulse">
            <img 
                src="https://maxtop.com.my/wp-content/themes/maxtop/assets/img/logo.svg" 
                alt="Maxtop" 
                class="h-20 w-auto object-contain filter brightness-0 invert" 
            />
        </div>

        <div class="bg-white w-full max-w-[400px] rounded-[30px] shadow-soft p-8 md:p-10 flex flex-col items-center relative z-10">
            
            <div class="text-center mb-8">
                <h2 class="text-xl font-bold text-gray-800">Welcome Back</h2>
                <p class="text-gray-400 text-xs tracking-widest uppercase mt-2 font-medium">B2B E-Ordering System</p>
            </div>

            @if (session('status'))
                <div class="mb-4 font-medium text-sm text-green-600">
                    {{ session('status') }}
                </div>
            @endif

            @if ($errors->any())
                <div class="w-full bg-red-50 text-red-500 text-xs p-3 rounded-xl text-center font-bold mb-4">
                    {{ __('Invalid credentials. Please try again.') }}
                </div>
            @endif

            <form method="POST" action="{{ route('login') }}" class="w-full space-y-5">
                @csrf

                <div class="space-y-1">
                    <label class="text-[11px] font-bold text-gray-400 ml-4 uppercase tracking-wider">{{ __('Username') }}</label>
                    <div class="relative group">
                        <div class="absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none">
                            <svg class="h-5 w-5 text-gray-400 group-focus-within:text-maxtop transition-colors" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                                <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z" />
                            </svg>
                        </div>
                        <input 
                            id="login_id" 
                            type="text" 
                            name="login_id" 
                            value="{{ old('login_id') }}" 
                            class="w-full pl-11 pr-4 py-4 bg-gray-50 border-none rounded-2xl text-gray-800 placeholder-gray-400 focus:bg-white focus:ring-2 focus:ring-maxtop/50 transition-all font-medium outline-none"
                            placeholder="Enter username"
                            required 
                            autofocus 
                        />
                    </div>
                </div>

                <div class="space-y-1">
                    <label class="text-[11px] font-bold text-gray-400 ml-4 uppercase tracking-wider">{{ __('Password') }}</label>
                    <div class="relative group">
                        <div class="absolute inset-y-0 left-0 pl-4 flex items-center pointer-events-none">
                            <svg class="h-5 w-5 text-gray-400 group-focus-within:text-maxtop transition-colors" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                                <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                            </svg>
                        </div>
                        <input 
                            id="password" 
                            type="password" 
                            name="password" 
                            class="w-full pl-11 pr-4 py-4 bg-gray-50 border-none rounded-2xl text-gray-800 placeholder-gray-400 focus:bg-white focus:ring-2 focus:ring-maxtop/50 transition-all font-medium outline-none"
                            placeholder="Enter password"
                            required 
                        />
                    </div>
                </div>

                <div class="flex items-center justify-between pt-2 px-2">
                    <label class="inline-flex items-center cursor-pointer">
                        <input id="remember_me" type="checkbox" class="rounded border-gray-300 text-maxtop focus:ring-maxtop h-4 w-4" name="remember">
                        <span class="ms-2 text-sm text-gray-500 font-medium">{{ __('Remember me') }}</span>
                    </label>

                    @if (Route::has('password.request'))
                        <a class="text-sm text-maxtop hover:text-green-700 font-bold transition-colors" href="{{ route('password.request') }}">
                            {{ __('Forgot?') }}
                        </a>
                    @endif
                </div>

                <button 
                 type="submit" 
                 class="w-full bg-maxtop hover:bg-[#46632c] text-white py-4 rounded-2xl font-bold text-lg shadow-lg shadow-maxtop/30 hover:shadow-xl hover:shadow-maxtop/40 hover:-translate-y-0.5 active:translate-y-0 active:scale-[0.98] transition-all duration-200 mt-4 ease-in-out">
                    {{ __('Sign In') }}
                </button>
            </form>
        </div>
        
        <div class="mt-8 text-white/40 text-xs font-medium tracking-wide">
            &copy; {{ date('Y') }} Maxtop. All rights reserved.
        </div>
    </div>
</body>
</html>
--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('On-going Orders (My Active Tasks)') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="mb-8">
            <x-filter-toolbar :placeholder="__('Search Order # or Customer Name...')" :showDates="true">
                <select name="status" class="text-xs border-gray-200 rounded-xl font-bold uppercase text-gray-600">
                    <option value="">{{ __('All Status') }}</option>
                    @foreach ($status as $statusName)
                        <option value="{{ $statusName }}" {{ request('status') == $statusName ? 'selected' : '' }}>
                            {{ ucfirst(str_replace('_', ' ', $statusName)) }}
                        </option>
                    @endforeach
                </select>
            </x-filter-toolbar>
        </div>
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6">
                @if ($myOrders->isEmpty())
                    <p class="text-gray-500 italic">{{ __('You are not currently handling any active orders.') }}</p>
                @else
                    <div class="overflow-x-auto">
                        <table class="w-full text-left border-collapse">
                            <thead>
                                <tr class="bg-gray-50 border-b">
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Order #') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Customer') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Status') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600 text-right">
                                        {{ __('Actions') }}</th>
                                </tr>
                            </thead>
                            <tbody>
                                @foreach ($myOrders as $order)
                                    <tr class="border-b hover:bg-gray-50 transition-colors">
                                        <td class="px-4 py-4 font-mono text-sm">{{ $order->order_number }}</td>
                                        <td class="px-4 py-4 text-sm font-bold text-gray-800">{{ $order->user->name }}
                                        </td>
                                        <td class="px-4 py-4">
                                            <span
                                                class="px-2 py-1 rounded-full text-[10px] font-black uppercase shadow-sm
                                                {{ $order->status === 'pending' ? 'bg-yellow-100 text-yellow-800 border border-yellow-300' : 'bg-blue-100 text-blue-800 border border-blue-300' }}">
                                                {{ $order->status }}
                                            </span>
                                        </td>
                                        <td class="px-4 py-4 text-right">
                                            @if (is_null($order->handler_id))
                                                <form action="{{ route('office.orders.claim', $order) }}"
                                                    method="POST">
                                                    @csrf
                                                    <button type="submit"
                                                        class="bg-blue-600 hover:bg-blue-700 text-white px-4 py-2 rounded-lg text-xs font-black uppercase shadow-md">
                                                        {{ __('Claim My Customer Order') }}
                                                    </button>
                                                </form>
                                            @else
                                                <a href="{{ route('office.orders.show', $order) }}"
                                                    class="inline-block bg-blue-50 text-blue-700 hover:bg-blue-700 hover:text-white px-4 py-2 rounded-lg text-xs font-black uppercase transition border border-blue-200">
                                                    {{ __('View & Process') }}
                                                </a>
                                            @endif
                                        </td>
                                    </tr>
                                @endforeach
                            </tbody>
                        </table>
                    </div>
                    <div class="mt-4">{{ $myOrders->links() }}</div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/cancellations.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('Cancellation Approval Queue') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">

            <div class="bg-white p-6 rounded-3xl border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('office.orders.cancellations') }}">
                    <x-filter-toolbar :placeholder="__('Search order # or customer...')" />
                </form>
            </div>

            <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th
                                class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Order Details') }}</th>
                            <th
                                class="px-6 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Requested By') }}</th>
                            <th
                                class="px-6 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Reason for Cancellation') }}</th>
                            <th
                                class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Action') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50 bg-white">
                        @forelse ($requests as $order)
                            <tr class="hover:bg-red-50/30 transition-colors">
                                <td class="px-8 py-5">
                                    <div class="flex flex-col">
                                        <span class="text-xs font-black text-gray-900">{{ $order->order_number }}</span>
                                        <span
                                            class="text-[10px] font-bold text-blue-600 uppercase">{{ $order->user->company->company_name ?? $order->user->name }}</span>
                                    </div>
                                </td>
                                <td class="px-6 py-5">
                                    <div class="flex items-center gap-2">
                                        <div class="w-2 h-2 bg-purple-500 rounded-full"></div>
                                        <span
                                            class="text-[10px] font-black text-gray-600 uppercase">{{ $order->cancellationRequester->name ?? __('Unknown Staff') }}</span>
                                    </div>
                                </td>
                                <td class="px-6 py-5">
                                    <p class="text-xs italic text-gray-500 leading-relaxed">
                                        "{{ $order->cancellation_request_reason }}"</p>
                                </td>
                                <td class="px-8 py-5 text-right">
                                    <div class="flex justify-end gap-2">
                                        <a href="{{ route('office.orders.show', $order) }}"
                                            class="px-4 py-2 bg-gray-100 hover:bg-gray-200 rounded-xl text-[10px] font-black uppercase text-gray-600 transition">
                                            {{ __('Review Details') }}
                                        </a>
                                        <form action="{{ route('office.orders.cancel', $order) }}" method="POST"
                                            onsubmit="return confirm('Confirm permanent cancellation?');">
                                            @csrf
                                            {{-- ARCHITECTURE FIX: Pass the existing request reason to the controller --}}
                                            <input type="hidden" name="cancellation_reason"
                                                value="{{ $order->cancellation_request_reason }}">

                                            <button type="submit"
                                                class="px-4 py-2 bg-red-600 hover:bg-red-700 rounded-xl text-[10px] font-black uppercase text-white shadow-md transition-all">
                                                {{ __('Approve Cancel') }}
                                            </button>
                                        </form>
                                    </div>
                                </td>
                            </tr>
                        @empty
                            <tr>
                                <td colspan="4" class="px-8 py-20 text-center">
                                    <p class="text-gray-400 font-black uppercase tracking-widest text-xs">
                                        {{ __('No pending cancellation requests found.') }}</p>
                                </td>
                            </tr>
                        @endforelse
                    </tbody>
                </table>
            </div>
            {{ $requests->links() }}
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/queue.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('⚠️ Claiming Queue (Unassigned Customers)') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6 border-l-4 border-orange-500">
                <div class="mb-6">
                    <form action="{{ route('office.orders.queue') }}" method="GET">
                        <x-filter-toolbar :placeholder="__('Search queue by Order # or Customer Name...')" />
                    </form>
                </div>

                @if ($unassigned->isEmpty())
                    <p class="text-gray-500 italic">{{ __('No new orders from unassigned customers.') }}</p>
                @else
                    <div class="overflow-x-auto">
                        <table class="w-full text-left border-collapse">
                            <thead>
                                <tr class="bg-gray-50 border-b">
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Order #') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">
                                        {{ __('Company / Customer') }}</th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">
                                        {{ __('Date Submitted') }}</th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600 text-right">
                                        {{ __('Action') }}</th>
                                </tr>
                            </thead>
                            <tbody>
                                @foreach ($unassigned as $order)
                                    <tr class="border-b hover:bg-orange-50 transition-colors">
                                        <td class="px-4 py-4 font-mono font-bold text-sm text-blue-600">
                                            {{ $order->order_number }}</td>
                                        <td class="px-4 py-4">
                                            <div class="font-bold text-gray-900">
                                                {{ $order->user->details->company_name ?? $order->user->name }}</div>
                                            <div class="text-xs text-gray-500">{{ $order->user->email }}</div>
                                        </td>
                                        <td class="px-4 py-4 text-sm text-gray-600">
                                            {{ $order->created_at->format('Y-m-d H:i') }}</td>
                                        <td class="px-4 py-4 text-right">
                                            <form action="{{ route('office.orders.claim', $order) }}" method="POST">
                                                @csrf
                                                <button type="submit"
                                                    class="bg-orange-600 hover:bg-orange-700 text-white px-4 py-2 rounded-lg text-xs font-black uppercase transition shadow-md">
                                                    {{ __('Claim Order') }}
                                                </button>
                                            </form>
                                        </td>
                                    </tr>
                                @endforeach
                            </tbody>
                        </table>
                    </div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/history.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('📋 My Claimed Orders Master List') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="mb-8">
            <x-filter-toolbar :placeholder="__('Search Order # or Customer Name...')" :showDates="true">
                <select name="status" class="text-xs border-gray-200 rounded-xl font-bold uppercase text-gray-600">
                    <option value="">{{ __('All Status') }}</option>
                    @foreach ($status as $statusName)
                        <option value="{{ $statusName }}" {{ request('status') == $statusName ? 'selected' : '' }}>
                            {{ ucfirst(str_replace('_', ' ', $statusName)) }}
                        </option>
                    @endforeach
                </select>
            </x-filter-toolbar>
        </div>
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6">
                @if ($history->isEmpty())
                    <div class="text-center py-8">
                        <p class="text-gray-500 italic">{{ __('You have not claimed any orders yet.') }}</p>
                    </div>
                @else
                    <div class="overflow-x-auto">
                        <table class="w-full text-left border-collapse">
                            <thead>
                                <tr class="bg-gray-50 border-b">
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Order #') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Customer') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">
                                        {{ __('Last Update') }}</th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Status') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600 text-right">
                                        {{ __('Actions') }}</th>
                                </tr>
                            </thead>
                            <tbody>
                                @foreach ($history as $order)
                                    <tr class="border-b hover:bg-gray-50 transition-colors">
                                        <td class="px-4 py-4 font-mono text-sm font-bold text-blue-600">
                                            {{ $order->order_number }}</td>
                                        <td class="px-4 py-4 text-sm">
                                            <div class="font-bold text-gray-900">
                                                {{ $order->user->details->company_name ?? $order->user->name }}</div>
                                            <div class="text-xs text-gray-400">{{ $order->user->email }}</div>
                                        </td>
                                        <td class="px-4 py-4 text-sm text-gray-600">
                                            {{ $order->updated_at->format('Y-m-d H:i') }}
                                        </td>
                                        <td class="px-4 py-4 text-sm">
                                            {{-- Fulfills Section 4: All Lifecycle Statuses --}}
                                            @php
                                                $statusClasses = match ($order->status) {
                                                    'pending' => 'bg-yellow-100 text-yellow-800 border-yellow-300',
                                                    'approved' => 'bg-green-100 text-green-800 border-green-300',
                                                    'in_transit' => 'bg-blue-100 text-blue-800 border-blue-300',
                                                    'completed' => 'bg-gray-100 text-gray-800 border-gray-300',
                                                    'cancelled' => 'bg-red-100 text-red-800 border-red-300',
                                                    default => 'bg-gray-50 text-gray-600 border-gray-200',
                                                };
                                            @endphp
                                            <span
                                                class="px-2 py-1 rounded-full text-[10px] font-black uppercase border shadow-sm {{ $statusClasses }}">
                                                {{ $order->status }}
                                            </span>
                                        </td>
                                        <td class="px-4 py-4 text-right">
                                            <a href="{{ route('office.orders.show', $order) }}"
                                                class="inline-block bg-white text-gray-700 hover:bg-gray-100 px-4 py-2 rounded-lg text-xs font-black uppercase transition border border-gray-200">
                                                {{ in_array($order->status, ['completed', 'cancelled']) ? __('View Summary') : __('Process Order') }}
                                            </a>
                                        </td>
                                    </tr>
                                @endforeach
                            </tbody>
                        </table>
                    </div>

                    <div class="mt-6">
                        {{ $history->links() }}
                    </div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/all.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Master Order Registry') }}
            </h2>
            <span
                class="px-4 py-2 bg-gray-900 text-white rounded-2xl text-[10px] font-black uppercase tracking-widest shadow-lg">
                {{ __('System-Wide Oversight') }}
            </span>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">

            {{-- THE SEARCH & FILTER TOOLBAR --}}
            <div class="bg-white p-6 rounded-[2rem] border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('office.orders.all') }}"
                    class="flex flex-col md:flex-row gap-4 items-center">
                    <div class="flex-1 w-full relative">
                        <x-text-input name="search" value="{{ request('search') }}"
                            placeholder="{{ __('Search by Order #, Customer, or Handler...') }}"
                            class="w-full pl-10 pr-4 py-3 rounded-2xl border-gray-100 focus:ring-blue-500" />
                        <svg class="w-5 h-5 text-gray-300 absolute left-3 top-3.5" fill="none" viewBox="0 0 24 24"
                            stroke="currentColor">
                            <path d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" />
                        </svg>
                    </div>

                    <select name="status"
                        class="w-full md:w-48 border-gray-100 rounded-2xl text-xs font-black uppercase text-gray-500 focus:ring-blue-500">
                        <option value="">{{ __('All Status') }}</option>
                        @foreach ($status as $s)
                            <option value="{{ $s }}" {{ request('status') == $s ? 'selected' : '' }}>
                                {{ str_replace('_', ' ', $s) }}</option>
                        @endforeach
                    </select>

                    <button type="submit"
                        class="bg-blue-600 hover:bg-blue-700 text-white px-8 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-md">
                        {{ __('Update Registry') }}
                    </button>

                    @if (request()->hasAny(['search', 'status']))
                        <a href="{{ route('office.orders.all') }}"
                            class="text-[10px] font-black uppercase text-red-400 hover:underline px-2">{{ __('Reset') }}</a>
                    @endif
                </form>
            </div>

            {{-- MASTER LIST TABLE --}}
            <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th
                                class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Order ID') }}</th>
                            <th
                                class="px-6 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Business Entity') }}</th>
                            <th
                                class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Status') }}</th>
                            <th
                                class="px-6 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Assigned Handler') }}</th>
                            <th
                                class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Action') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50 bg-white">
                        @foreach ($allOrders as $order)
                            <tr class="hover:bg-gray-50 transition-colors">
                                <td class="px-8 py-5">
                                    <span
                                        class="text-sm font-mono font-black text-blue-600 uppercase">{{ $order->order_number ?? '---' }}</span>
                                    <p class="text-[9px] text-gray-400 font-bold uppercase mt-1">
                                        {{ $order->created_at->format('d M Y H:i') }}</p>
                                </td>
                                <td class="px-6 py-5">
                                    <span
                                        class="text-xs font-black text-gray-700 uppercase block">{{ $order->user->company->company_name ?? $order->user->name }}</span>
                                    <span
                                        class="text-[9px] font-mono text-gray-400 uppercase">{{ $order->user->company->company_code ?? ($order->user->company->branch_code ?? 'NO_CODE') }}</span>
                                </td>
                                <td class="px-6 py-5 text-center">
                                    <span
                                        class="px-3 py-1 rounded-full text-[9px] font-black uppercase border 
                                        {{ $order->status === 'pending' ? 'bg-yellow-50 text-yellow-700 border-yellow-200' : '' }}
                                        {{ $order->status === 'approved' ? 'bg-green-50 text-green-700 border-green-200' : '' }}
                                        {{ $order->status === 'in_transit' ? 'bg-blue-50 text-blue-700 border-blue-200' : '' }}
                                        {{ $order->status === 'completed' ? 'bg-gray-50 text-gray-700 border-gray-200' : '' }}
                                        {{ $order->status === 'cancelled' ? 'bg-red-50 text-red-700 border-red-200' : '' }}
                                        {{ $order->status === 'draft' ? 'bg-gray-50 text-gray-400 border-gray-200' : '' }}">
                                        {{ str_replace('_', ' ', $order->status) }}
                                    </span>
                                </td>
                                <td class="px-6 py-5">
                                    @if ($order->handler)
                                        <div class="flex items-center gap-2">
                                            <div
                                                class="w-6 h-6 bg-indigo-100 rounded-lg flex items-center justify-center text-indigo-600 text-[9px] font-black">
                                                {{ substr($order->handler->name, 0, 1) }}
                                            </div>
                                            <span
                                                class="text-[10px] font-black text-gray-600 uppercase">{{ $order->handler->name }}</span>
                                        </div>
                                    @else
                                        <span
                                            class="text-[9px] font-black text-amber-500 uppercase italic">{{ __('Unassigned') }}</span>
                                    @endif
                                </td>
                                <td class="px-8 py-5 text-right">
                                    <a href="{{ route('office.orders.show', $order) }}"
                                        class="inline-block bg-white border border-gray-200 text-gray-700 px-4 py-2 rounded-xl text-[10px] font-black uppercase hover:bg-gray-50 transition shadow-sm">
                                        {{ __('Audit Order') }}
                                    </a>
                                </td>
                            </tr>
                        @endforeach
                    </tbody>
                </table>
            </div>

            {{ $allOrders->links() }}
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/dashboard.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('Unified Order Dashboard') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">

            {{-- Stats Container: Addendum Section 4.b --}}
            <div class="grid grid-cols-2 md:grid-cols-3 lg:grid-cols-6 gap-4 mb-8">
                @foreach ($stats as $label => $count)
                    <div
                        class="bg-white p-6 rounded-3xl shadow-sm border border-gray-100 text-center transition-transform hover:scale-105">
                        <p class="text-[10px] font-black uppercase tracking-widest text-gray-400 mb-1">
                            {{ $label }}</p>
                        <p class="text-3xl font-black text-gray-800">{{ number_format($count) }}</p>
                    </div>
                @endforeach
            </div>

            {{-- Operational Shortcuts Container --}}
            <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                <div class="bg-white p-8 rounded-3xl border border-gray-100 shadow-sm">
                    <h3 class="font-black text-gray-800 uppercase text-sm mb-6 flex items-center gap-2">
                        <svg class="w-5 h-5 text-blue-600" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2.5"
                                d="M13 10V3L4 14h7v7l9-11h-7z" />
                        </svg>
                        {{ __('Quick Actions') }}
                    </h3>

                    <div class="grid grid-cols-1 sm:grid-cols-2 gap-3">
                        {{-- On-going Orders: Fulfills Section 5.a --}}
                        <a href="{{ route('office.orders.index') }}"
                            class="flex items-center justify-center bg-blue-600 text-white px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-blue-700 transition shadow-sm">
                            {{ __('On-going Orders') }}
                        </a>

                        {{-- Claiming Queue: Fulfills Section 5.b --}}
                        <a href="{{ route('office.orders.queue') }}"
                            class="flex items-center justify-center bg-orange-600 text-white px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-orange-700 transition shadow-sm">
                            {{ __('Claiming Queue') }}
                        </a>

                        {{-- My Claimed Orders: Fulfills Section 5.c --}}
                        <a href="{{ route('office.orders.history') }}"
                            class="flex items-center justify-center bg-gray-800 text-white px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-gray-900 transition shadow-sm">
                            {{ __('My Claimed Orders') }}
                        </a>

                        {{-- Product Management: Fulfills Section 2.c.1 --}}
                        <a href="{{ route('items.index') }}"
                            class="flex items-center justify-center border-2 border-blue-600 text-blue-600 px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-blue-50 transition">
                            {{ __('Manage Products') }}
                        </a>

                        @hasanyrole('admin|cs_leader')
                            <a href="{{ route('office.orders.cancellations') }}"
                                class="relative flex items-center justify-center bg-red-600 text-white px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-red-700 transition shadow-lg shadow-red-900/20">
                                {{ __('Cancellation Requests') }}
                                @php $requestCount = \App\Models\Order::where('status', 'cancellation_requested')->count(); @endphp
                                @if ($requestCount > 0)
                                    <span
                                        class="absolute -top-2 -right-2 bg-white text-red-600 w-5 h-5 rounded-full flex items-center justify-center text-[9px] border-2 border-red-600 shadow-sm animate-bounce">
                                        {{ $requestCount }}
                                    </span>
                                @endif
                            </a>

                            <a href="{{ route('office.orders.all') }}"
                                class="flex items-center justify-center bg-indigo-600 text-white px-4 py-3 rounded-xl text-[10px] font-black uppercase hover:bg-indigo-700 transition shadow-lg shadow-indigo-100">
                                {{ __('All System Orders') }}
                            </a>
                        @endhasanyrole
                    </div>
                </div>

                {{-- Active Session Context --}}
                <div
                    class="bg-white p-8 rounded-3xl border border-gray-100 shadow-sm flex items-center justify-between">
                    <div class="flex items-center">
                        <div class="p-4 bg-blue-50 rounded-2xl mr-4 text-blue-600">
                            <svg class="w-8 h-8" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                                <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
                                    d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z" />
                            </svg>
                        </div>
                        <div>
                            <p class="text-xs text-gray-400 font-bold uppercase tracking-widest">
                                {{ __('Active Staff') }}</p>
                            <p class="text-xl font-black text-gray-800 capitalize">{{ auth()->user()->name }}</p>
                            <p class="text-[10px] text-blue-500 font-mono font-bold">
                                {{ auth()->user()->roles->first()->name }}</p>
                        </div>
                    </div>

                    <div class="text-right">
                        <p class="text-[10px] text-gray-400 font-black uppercase mb-1">{{ __('Today') }}</p>
                        <p class="text-sm font-black text-gray-800">{{ now()->format('d M Y') }}</p>
                    </div>
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/cs/orders/show.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <div>
                <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                    {{ __('Order Fulfillment') }}: <span
                        class="text-blue-600">{{ $order->order_number ?? __('DRAFT') }}</span>
                </h2>
                <div class="mt-1 flex items-center gap-2">
                    <span
                        class="px-3 py-1 rounded-full text-[10px] font-black uppercase border shadow-sm 
                        {{ $order->status === 'pending' ? 'bg-yellow-100 text-yellow-800 border-yellow-300' : '' }}
                        {{ $order->status === 'approved' ? 'bg-green-100 text-green-800 border-green-300' : '' }}
                        {{ $order->status === 'in_transit' ? 'bg-blue-100 text-blue-800 border-blue-300' : '' }}
                        {{ $order->status === 'completed' ? 'bg-gray-100 text-gray-800 border-gray-300' : '' }}
                        {{ $order->status === 'cancelled' ? 'bg-red-100 text-red-800 border-red-300' : '' }}
                        {{ $order->status === 'draft' ? 'bg-gray-50 text-gray-500 border-gray-200' : '' }}
                        {{ $order->status === 'cancellation_requested' ? 'bg-purple-100 text-purple-800 border-purple-300' : '' }}">
                        {{ str_replace('_', ' ', $order->status) }}
                    </span>
                </div>
            </div>
            <a href="{{ route('office.orders.index') }}"
                class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                &larr; {{ __('Back to Workspace') }}
            </a>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">

            {{-- 1. OWNERSHIP & STATE ALERTS [Backbone 4.a, 4.b] --}}
            @if ($order->status === 'draft')
                <div class="bg-amber-50 border-l-4 border-amber-400 p-6 rounded-2xl flex items-center gap-4 shadow-sm">
                    <svg class="w-8 h-8 text-amber-500" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                        stroke-width="2.5">
                        <path
                            d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                    </svg>
                    <p class="text-xs font-black text-amber-800 uppercase leading-relaxed tracking-tight">
                        {{ __('Customer Editing: This order is currently in DRAFT status. Operational actions (Approve/Ship) are locked until the customer re-submits for review.') }}
                    </p>
                </div>
            @elseif(
                $order->handler_id !== auth()->id() &&
                    !auth()->user()->hasAnyRole(['admin', 'cs_leader']))
                <div class="bg-blue-50 border-l-4 border-blue-400 p-6 rounded-2xl flex items-center gap-4 shadow-sm">
                    <svg class="w-8 h-8 text-blue-500" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                        stroke-width="2.5">
                        <path
                            d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z" />
                    </svg>
                    <p class="text-xs font-black text-blue-800 uppercase leading-relaxed tracking-tight">
                        {{ __('Read-Only Mode: You are not the current handler. Only ') . ($order->handler->name ?? __('Unassigned Staff')) . __(' can process this order.') }}
                    </p>
                </div>
            @endif

            <div class="grid grid-cols-1 lg:grid-cols-3 gap-8">
                {{-- LEFT COLUMN: MANIFEST & LOGS --}}
                <div class="lg:col-span-2 space-y-8">

                    {{-- 2. ORDER ITEMS [Addendum 5.a] --}}
                    <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100">
                        <div class="p-8 border-b border-gray-50 flex justify-between items-center">
                            <h3 class="text-[10px] font-black uppercase text-gray-400 tracking-widest">
                                {{ __('Reservation Manifest') }}</h3>
                            <span class="text-[10px] font-black text-blue-600 uppercase">{{ $order->items->count() }}
                                {{ __('Line Items') }}</span>
                        </div>
                        <table class="min-w-full divide-y divide-gray-100">
                            <thead class="bg-gray-50">
                                <tr>
                                    <th
                                        class="px-8 py-4 text-left text-[9px] font-black text-gray-400 uppercase tracking-widest">
                                        {{ __('Product Details') }}</th>
                                    <th
                                        class="px-6 py-4 text-center text-[9px] font-black text-gray-400 uppercase tracking-widest">
                                        {{ __('Packaging Unit') }}</th>
                                    <th
                                        class="px-6 py-4 text-center text-[9px] font-black text-gray-400 uppercase tracking-widest">
                                        {{ __('Qty') }}</th>
                                    <th
                                        class="px-8 py-4 text-right text-[9px] font-black text-gray-400 uppercase tracking-widest">
                                        {{ __('Unit Price') }}</th>
                                </tr>
                            </thead>
                            <tbody class="divide-y divide-gray-50 bg-white">
                                @foreach ($order->items as $item)
                                    <tr class="hover:bg-gray-50/50 transition-colors">
                                        <td class="px-8 py-4">
                                            <div class="flex flex-col">
                                                <span
                                                    class="text-[10px] font-mono font-black text-blue-600 uppercase">{{ $item->item->sku }}</span>
                                                <span class="text-xs font-black text-gray-700 uppercase">
                                                    {{ in_array($order->status, ['draft', 'pending']) ? $item->item->name : $item->snapshot_name }}
                                                </span>
                                            </div>
                                        </td>
                                        <td class="px-6 py-4 text-center">
                                            <span
                                                class="px-3 py-1 rounded-full text-[10px] font-black uppercase {{ $item->uom_id ? 'bg-blue-50 text-blue-600 border border-blue-100' : 'bg-gray-50 text-gray-400' }}">
                                                {{ in_array($order->status, ['draft', 'pending']) ? $item->uom->uom_name ?? __('Individual Unit') : $item->snapshot_uom_name }}
                                            </span>
                                        </td>
                                        <td class="px-6 py-4 text-center font-mono font-black text-sm text-gray-900">
                                            {{ $item->quantity }}</td>
                                        <td class="px-8 py-4 text-right font-mono font-black text-sm text-gray-600">
                                            {{-- ARCHITECTURE FIX: Display Live UOM price if snapshot hasn't happened yet --}}
                                            @if (in_array($order->status, ['draft', 'pending']))
                                                RM {{ number_format($item->uom->price ?? 0.0, 2) }}
                                            @else
                                                RM {{ number_format($item->price_at_order, 2) }}
                                            @endif
                                        </td>
                                    </tr>
                                @endforeach
                            </tbody>
                        </table>
                    </div>

                    {{-- 3. INTERNAL OFFICE NOTES [Backbone 6.b] --}}
                    <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm">
                        <h3 class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                            {{ __('Internal Office Log (Private)') }}</h3>
                        <form action="{{ route('office.orders.updateStatus', $order) }}" method="POST"
                            class="space-y-4">
                            @csrf
                            @method('PUT')
                            <input type="hidden" name="status" value="{{ $order->status }}">
                            <textarea name="internal_notes" rows="4"
                                class="w-full border-gray-200 rounded-[1.5rem] text-sm focus:ring-blue-500 placeholder-gray-300"
                                placeholder="{{ __('Add staff-only comments, delivery instructions, or verification notes...') }}">{{ old('internal_notes', $order->internal_notes) }}</textarea>
                            <div class="flex justify-end">
                                <x-primary-button
                                    class="bg-gray-800 hover:bg-black py-2 px-6 rounded-xl text-[9px] font-black uppercase shadow-lg shadow-gray-200">
                                    {{ __('Update Internal Log') }}
                                </x-primary-button>
                            </div>
                        </form>
                    </div>

                    {{-- 4. PRIVILEGED AUDIT TRAIL [Internal Order Audit Protocol] --}}
                    @hasanyrole('admin|cs_leader')
                        <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100">
                            <div class="p-8 border-b border-gray-50 flex items-center gap-2">
                                <svg class="w-4 h-4 text-gray-400" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                                    stroke-width="2.5">
                                    <path
                                        d="M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z" />
                                </svg>
                                <h3 class="text-[10px] font-black uppercase text-gray-400 tracking-widest">
                                    {{ __('Internal Audit Trail: Status Transitions') }}</h3>
                            </div>
                            <div class="p-8 space-y-4">
                                @forelse ($order->statusHistory as $history)
                                    <div
                                        class="flex items-center justify-between p-4 bg-gray-50 rounded-2xl border border-gray-100">
                                        <div class="flex items-center gap-4">
                                            <span
                                                class="px-2.5 py-1 bg-white border border-gray-200 rounded-lg text-[9px] font-black uppercase text-gray-600 shadow-sm">
                                                {{ str_replace('_', ' ', $history->status) }}
                                            </span>
                                            <div class="flex flex-col">
                                                <span
                                                    class="text-[10px] font-black text-gray-900 uppercase tracking-tight">{{ $history->changer->name }}</span>
                                                <span
                                                    class="text-[8px] font-bold text-blue-500 uppercase">{{ $history->changer->roles->first()->name }}</span>
                                            </div>
                                        </div>
                                        <span
                                            class="text-[9px] font-black text-gray-400 uppercase">{{ $history->created_at->format('d M Y, H:i') }}</span>
                                    </div>
                                @empty
                                    <p class="text-[10px] text-gray-400 italic uppercase text-center py-4">
                                        {{ __('No status transition records found.') }}</p>
                                @endforelse
                            </div>
                        </div>
                    @endhasanyrole
                </div>

                {{-- RIGHT COLUMN: ENTITY INFO & ACTIONS --}}
                <div class="space-y-8">

                    {{-- 5. CUSTOMER ENTITY CARD [Addendum 1.a] --}}
                    <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm">
                        <h3
                            class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest border-b border-gray-50 pb-2">
                            {{ __('Business Information') }}</h3>
                        <div class="flex items-center gap-4 mb-6">
                            <div
                                class="w-12 h-12 bg-blue-600 rounded-2xl flex items-center justify-center text-white text-xs font-black uppercase shadow-lg shadow-blue-100">
                                {{ is_null($order->user->company?->parent_id) ? 'HQ' : 'BR' }}
                            </div>
                            <div class="flex flex-col">
                                <span
                                    class="text-sm font-black text-gray-900 uppercase leading-tight">{{ $order->user->company->company_name ?? $order->user->name }}</span>
                                <span class="text-[10px] font-mono text-blue-500 font-bold uppercase tracking-tighter">
                                    {{ $order->user->company->company_code ?? ($order->user->company->branch_code ?? 'N/A') }}
                                </span>
                            </div>
                        </div>
                        <div class="space-y-4">
                            <div>
                                <span
                                    class="text-[9px] font-black text-gray-400 uppercase block mb-1 tracking-tighter">{{ __('Delivery Address') }}</span>
                                <p class="text-xs font-bold text-gray-700 leading-relaxed italic">
                                    {{ $order->user->company->delivery_address ?? __('No address on file') }}</p>
                            </div>
                            <div class="grid grid-cols-2 gap-4">
                                <div>
                                    <span
                                        class="text-[9px] font-black text-gray-400 uppercase block mb-1">{{ __('PIC Name') }}</span>
                                    <p class="text-xs font-bold text-gray-700 uppercase">
                                        {{ $order->user->company->pic_name ?? $order->user->name }}</p>
                                </div>
                                <div>
                                    <span
                                        class="text-[9px] font-black text-gray-400 uppercase block mb-1">{{ __('PIC Contact') }}</span>
                                    <p class="text-xs font-bold text-gray-700">
                                        {{ $order->user->company->pic_phone ?? 'N/A' }}</p>
                                </div>
                            </div>
                        </div>
                    </div>

                    {{-- 6. FULFILLMENT ACTIONS [Backbone 4, Addendum 4] --}}
                    @if (!in_array($order->status, ['completed', 'cancelled']))
                        <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm space-y-6">
                            <h3
                                class="text-[10px] font-black uppercase text-gray-400 tracking-widest border-b border-gray-50 pb-2">
                                {{ __('Fulfillment Protocol') }}</h3>

                            {{-- CLAIM [Backbone 5.b] --}}
                            @if (is_null($order->handler_id))
                                <form action="{{ route('office.orders.claim', $order) }}" method="POST">
                                    @csrf
                                    <button type="submit"
                                        class="w-full bg-blue-600 hover:bg-blue-700 text-white py-4 rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-blue-100">
                                        {{ __('Claim This Order') }}
                                    </button>
                                </form>
                            @endif

                            {{-- APPROVAL [Backbone 4.c] --}}
                            @if ($order->status === 'pending' && $order->handler_id === auth()->id())
                                <form action="{{ route('office.orders.approve', $order) }}" method="POST"
                                    onsubmit="return confirm('{{ __('Are you sure? This will freeze item names and packaging rates for B2B historical accuracy.') }}');">
                                    @csrf
                                    <button type="submit"
                                        class="w-full bg-green-600 hover:bg-green-700 text-white py-4 rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-green-900/40">
                                        {{ __('Approve & Snapshot') }}
                                    </button>
                                </form>
                            @endif

                            {{-- DISPATCH [Backbone 4.d] --}}
                            @if ($order->status === 'approved' && $order->handler_id === auth()->id())
                                <form action="{{ route('office.orders.updateStatus', $order) }}" method="POST"
                                    class="space-y-4">
                                    @csrf
                                    @method('PUT')
                                    <input type="hidden" name="status" value="in_transit">
                                    <div>
                                        <label
                                            class="text-[9px] font-black text-gray-500 uppercase block mb-2">{{ __('Logistics Provider') }}</label>
                                        <input type="text" name="logistics_carrier" required
                                            class="w-full bg-gray-50 border-gray-200 rounded-xl text-sm"
                                            placeholder="e.g. DHL, Skynet">
                                    </div>
                                    <div>
                                        <label
                                            class="text-[9px] font-black text-gray-500 uppercase block mb-2">{{ __('Tracking Reference #') }}</label>
                                        <input type="text" name="tracking_number" required
                                            class="w-full bg-gray-50 border-gray-200 rounded-xl text-sm"
                                            placeholder="e.g. TRK990122">
                                    </div>
                                    <button type="submit"
                                        class="w-full bg-blue-600 hover:bg-blue-700 text-white py-4 rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-blue-100">
                                        {{ __('Mark In Transit') }}
                                    </button>
                                </form>
                            @endif

                            {{-- DANGER ZONE: CANCELLATION --}}
                            <div class="pt-6 border-t border-red-50 space-y-4">
                                @if ($order->hasPendingCancellationRequest())
                                    <div class="bg-purple-50 p-4 rounded-2xl border border-purple-100">
                                        <h4 class="text-[10px] font-black text-purple-700 uppercase mb-2">
                                            {{ __('Cancellation Pending Approval') }}</h4>
                                        <p class="text-[10px] text-purple-600 italic mb-4">
                                            "{{ $order->cancellation_request_reason }}"</p>

                                        @hasanyrole('admin|cs_leader')
                                            <form action="{{ route('office.orders.cancel', $order) }}" method="POST"
                                                class="space-y-3">
                                                @csrf
                                                <input type="text" name="cancellation_reason"
                                                    class="w-full bg-white border-purple-200 rounded-xl text-xs"
                                                    placeholder="{{ __('Final manager approval note...') }}" />
                                                <button type="submit"
                                                    class="w-full bg-red-600 hover:bg-red-700 text-white py-2.5 rounded-xl text-[10px] font-black uppercase transition shadow-md">
                                                    {{ __('Confirm Cancellation') }}
                                                </button>
                                            </form>
                                        @else
                                            <div
                                                class="py-2 px-4 bg-purple-100 rounded-xl text-[9px] font-black text-purple-400 uppercase text-center italic tracking-widest">
                                                {{ __('Awaiting Manager Review') }}
                                            </div>
                                        @endhasanyrole
                                    </div>
                                @elseif(
                                    $order->handler_id === auth()->id() ||
                                        auth()->user()->hasAnyRole(['admin', 'cs_leader']))
                                    <form action="{{ route('office.orders.cancel', $order) }}" method="POST"
                                        class="space-y-3">
                                        @csrf
                                        <div>
                                            <input type="text" name="cancellation_reason" required
                                                class="w-full bg-gray-50 border-gray-200 rounded-xl text-sm"
                                                placeholder="{{ __('Reason for cancellation (min 5 chars)...') }}" />
                                            <x-input-error :messages="$errors->get('cancellation_reason')" class="mt-1" />
                                        </div>
                                        <button type="submit"
                                            class="w-full border-2 border-red-100 text-red-500 hover:bg-red-50 py-3 rounded-2xl text-[10px] font-black uppercase transition-all">
                                            @if ($order->status === 'approved' && auth()->user()->hasRole('cs_staff'))
                                                {{ __('Request Order Cancellation') }}
                                            @else
                                                {{ __('Cancel Order') }}
                                            @endif
                                        </button>
                                    </form>
                                @endif
                            </div>
                        </div>
                    @endif

                    {{-- 7. HANDOVER PROTOCOL [Backbone 5.d] --}}
                    @if (auth()->user()->hasAnyRole(['admin', 'cs_leader']) || $order->handler_id === auth()->id())
                        <div class="bg-orange-50 p-8 rounded-[2.5rem] border border-orange-100 shadow-sm space-y-4">
                            <h3
                                class="text-[10px] font-black uppercase text-orange-700 tracking-widest border-b border-orange-200/50 pb-2">
                                {{ __('Handler Assignment') }}</h3>
                            <form action="{{ route('office.orders.handover', $order) }}" method="POST"
                                class="space-y-4">
                                @csrf
                                <select name="new_handler_id"
                                    class="w-full border-orange-200 rounded-xl text-xs font-bold focus:ring-orange-500 bg-white">
                                    <option value="">{{ __('-- Transfer to Staff --') }}</option>
                                    @foreach ($eligibleStaff as $staff)
                                        <option value="{{ $staff->id }}">{{ $staff->name }}
                                            ({{ str_replace('_', ' ', $staff->roles->first()->name) }})
                                        </option>
                                    @endforeach
                                </select>
                                <button type="submit"
                                    class="w-full bg-orange-600 hover:bg-orange-700 text-white py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-md shadow-orange-200">
                                    {{ __('Handover Authority') }}
                                </button>
                            </form>
                        </div>
                    @endif
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/activity/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('System Activity Log') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6">

                {{-- THE DYNAMIC SEARCH TOOLBAR [4] --}}
                <div class="mb-6">
                    <x-filter-toolbar :placeholder="__('Search Name or Login ID...')">
                        {{-- Action Type Dropdown --}}
                        <select name="action_type"
                            class="text-sm border-gray-300 rounded-md focus:ring-blue-500 focus:border-blue-500">
                            <option value="">{{ __('All Actions') }}</option>
                            @foreach ($actionTypes as $type)
                                <option value="{{ $type }}"
                                    {{ request('action_type') == $type ? 'selected' : '' }}>
                                    {{ ucfirst($type) }}
                                </option>
                            @endforeach
                        </select>

                        {{-- Role Dropdown --}}
                        <select name="role"
                            class="text-sm border-gray-300 rounded-md focus:ring-blue-500 focus:border-blue-500">
                            <option value="">{{ __('All Roles') }}</option>
                            @foreach ($roles as $roleName)
                                <option value="{{ $roleName }}"
                                    {{ request('role') == $roleName ? 'selected' : '' }}>
                                    {{ ucfirst(str_replace('_', ' ', $roleName)) }}
                                </option>
                            @endforeach
                        </select>
                    </x-filter-toolbar>
                </div>

                {{-- LOG TABLE --}}
                {{-- LOG TABLE --}}
                <div class="overflow-x-auto">
                    <table class="min-w-full divide-y divide-gray-200">
                        <thead class="bg-gray-50">
                            <tr>
                                <th
                                    class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                    Time</th>
                                <th
                                    class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                    User (Causer)</th>
                                <th
                                    class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                    Action</th>
                                <th
                                    class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                    Target (Subject)</th>
                                <th
                                    class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
                                    Changes</th>
                            </tr>
                        </thead>
                        <tbody class="bg-white divide-y divide-gray-200">
                            @foreach ($logs as $log)
                                <tr>
                                    <td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">
                                        {{ $log->created_at->format('Y-m-d H:i:s') }}
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">
                                        {{ $log->causer->name ?? 'System' }}
                                        <span
                                            class="text-xs text-gray-400">({{ $log->causer->login_id ?? 'N/A' }})</span>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap text-sm">
                                        <span
                                            class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full 
                                            {{ $log->description === 'updated' ? 'bg-yellow-100 text-yellow-800' : 'bg-green-100 text-green-800' }}">
                                            {{ ucfirst($log->description) }}
                                        </span>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap text-sm text-gray-600">
                                        {{ class_basename($log->subject_type) }} (ID: {{ $log->subject_id }})
                                    </td>
                                    <td class="px-6 py-4 text-sm text-gray-500">
                                        {{-- Displaying Old vs New values from the 'properties' JSON --}}
                                        @if (isset($log->properties['attributes']))
                                            <div class="text-xs">
                                                <strong>New:</strong>
                                                @foreach ($log->properties['attributes'] as $key => $value)
                                                    {{ $key }}:
                                                    {{ is_array($value) ? json_encode($value) : $value }},
                                                @endforeach
                                            </div>
                                        @endif
                                        @if (isset($log->properties['old']))
                                            <div class="text-xs mt-1 text-red-400">
                                                <strong>Old:</strong>
                                                @foreach ($log->properties['old'] as $key => $value)
                                                    {{ $key }}:
                                                    {{ is_array($value) ? json_encode($value) : $value }},
                                                @endforeach
                                            </div>
                                        @endif
                                    </td>
                                </tr>
                            @endforeach
                        </tbody>
                    </table>
                </div>

                <div class="mt-4">
                    {{ $logs->links() }}
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/roles/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('System Role Registry') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">

            {{-- CREATE SECTION --}}
            <div class="bg-white p-8 rounded-[2rem] border border-gray-100 shadow-sm">
                <form method="POST" action="{{ route('admin.roles.manage.store') }}"
                    class="flex flex-col md:flex-row gap-4 items-end">
                    @csrf
                    <div class="flex-1">
                        <x-input-label :value="__('New Custom Role Name')" class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                        <x-text-input name="name" required placeholder="e.g. branch_manager" class="w-full" />
                    </div>
                    <x-primary-button
                        class="bg-blue-600 hover:bg-blue-700 h-12 px-8 rounded-xl text-[10px] font-black uppercase">
                        {{ __('Add Custom Role') }}
                    </x-primary-button>
                </form>
                <p class="mt-3 text-[9px] text-gray-400 uppercase italic">
                    {{ __('Note: Creating an "Admin" role is programmatically restricted to maintain single-authority integrity.') }}
                </p>
            </div>

            {{-- LIST SECTION --}}
            <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th
                                class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Role Identity') }}</th>
                            <th
                                class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Active Users') }}</th>
                            <th
                                class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Registry Status') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50 bg-white">
                        @foreach ($roles as $role)
                            <tr class="hover:bg-gray-50 transition-colors">
                                <td class="px-8 py-5">
                                    <span
                                        class="text-sm font-black text-gray-900 uppercase">{{ str_replace('_', ' ', $role->name) }}</span>
                                </td>
                                <td class="px-6 py-5 text-center">
                                    <span
                                        class="px-3 py-1 bg-indigo-50 text-indigo-700 rounded-full text-[10px] font-black uppercase">
                                        {{ $role->users_count }} {{ __('Users') }}
                                    </span>
                                </td>
                                <td class="px-8 py-5 text-right">
                                    @if (in_array($role->name, $protectedRoles))
                                        <span
                                            class="text-[9px] font-black text-amber-500 uppercase tracking-widest border border-amber-200 px-3 py-1 rounded-lg bg-amber-50">
                                            {{ __('ðŸ”’ System Protected') }}
                                        </span>
                                    @else
                                        <form action="{{ route('admin.roles.manage.destroy', $role) }}" method="POST"
                                            onsubmit="return confirm('Permanently remove this role?');">
                                            @csrf @method('DELETE')
                                            <button type="submit"
                                                class="text-red-400 hover:text-red-600 text-[10px] font-black uppercase tracking-widest transition">
                                                {{ __('Remove Role') }}
                                            </button>
                                        </form>
                                    @endif
                                </td>
                            </tr>
                        @endforeach
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/roles/matrix.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('Feature Access Control') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100">
                <div class="p-8 text-gray-900">
                    <div class="mb-8">
                        <h3 class="text-lg font-black uppercase text-gray-800 tracking-tight">
                            {{ __('Permission Matrix') }}</h3>
                        <p class="text-xs text-gray-500 uppercase font-bold mt-1">
                            {{ __('Check the box to enable a feature for a specific role.') }}</p>
                    </div>

                    {{-- ARCHITECTURE FIX: Updated route name to 'admin.roles.update' to match web.php definitions --}}
                    <form action="{{ route('admin.roles.update') }}" method="POST">
                        @csrf
                        <div class="overflow-x-auto border border-gray-100 rounded-3xl">
                            <table class="min-w-full divide-y divide-gray-100">
                                <thead class="bg-gray-50">
                                    <tr>
                                        <th
                                            class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider border-r">
                                            {{ __('Feature / Role') }}
                                        </th>
                                        @foreach ($roles as $role)
                                            <th
                                                class="px-6 py-3 text-center text-xs font-medium text-gray-500 uppercase tracking-wider">
                                                {{ ucfirst(str_replace('_', ' ', $role->name)) }}
                                            </th>
                                        @endforeach
                                    </tr>
                                </thead>
                                <tbody class="bg-white divide-y divide-gray-50">
                                    @foreach ($permissions as $permission)
                                        <tr>
                                            <td
                                                class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900 border-r bg-gray-50">
                                                {{ ucfirst(str_replace('_', ' ', $permission->name)) }}
                                            </td>
                                            @foreach ($roles as $role)
                                                @php
                                                    $isAdmin = $role->name === 'admin';
                                                    $hasPermission = $role->hasPermissionTo($permission->name);
                                                    $isChecked = $isAdmin || $hasPermission;
                                                    $isDisabled = $isAdmin;
                                                @endphp
                                                <td class="px-6 py-4 whitespace-nowrap text-center">
                                                    <input type="checkbox" name="matrix[{{ $role->id }}][]"
                                                        value="{{ $permission->id }}"
                                                        class="rounded border-gray-300 text-indigo-600 shadow-sm focus:ring-indigo-500"
                                                        @if ($isChecked) checked @endif
                                                        @if ($isDisabled) disabled @endif>

                                                    {{-- SECURITY GUARD: Ensure Admin always retains all permissions [Backbone 2.a] --}}
                                                    @if ($isAdmin)
                                                        <input type="hidden" name="matrix[{{ $role->id }}][]"
                                                            value="{{ $permission->id }}">
                                                    @endif
                                                </td>
                                            @endforeach
                                        </tr>
                                    @endforeach
                                </tbody>
                            </table>
                        </div>

                        <div class="mt-8 flex justify-end">
                            <x-primary-button
                                class="bg-blue-600 hover:bg-blue-700 px-8 py-3 rounded-xl text-[10px] font-black uppercase shadow-lg shadow-blue-100">
                                {{ __('Save Feature Matrix') }}
                            </x-primary-button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/companys/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex justify-between items-center">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Business Entities') }}
            </h2>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">
            <a href="{{ route('companys.create') }}"
                class="bg-blue-600 hover:bg-blue-700 text-white px-5 py-2.5 rounded-2xl text-xs font-black uppercase shadow-lg shadow-blue-200 transition-all">
                {{ __('Register New Business') }}
            </a>
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th
                                class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Business Name / Code') }}</th>
                            <th
                                class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Assigned Catalog') }}</th>
                            <th
                                class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Logistics') }}</th>
                            <th
                                class="px-6 py-4 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                {{ __('Actions') }}</th>
                        </tr>
                    </thead>
                    <tbody class="bg-white divide-y divide-gray-50">
                        @foreach ($companys as $hq)
                            {{-- HQ Row --}}
                            <tr class="bg-blue-50/30">
                                <td class="px-6 py-4">
                                    <div class="flex items-center gap-3">
                                        <div
                                            class="w-8 h-8 bg-blue-600 rounded-lg flex items-center justify-center text-white text-xs font-black">
                                            HQ</div>
                                        <div class="flex flex-col">
                                            <span class="text-sm font-bold text-gray-900">{{ $hq->company_name }}</span>
                                            <span
                                                class="text-[10px] font-mono text-blue-500 uppercase font-black">{{ $hq->company_code }}</span>
                                        </div>
                                    </div>
                                </td>
                                <td class="px-6 py-4">
                                    <span
                                        class="px-3 py-1 rounded-full bg-white border border-blue-200 text-blue-700 text-[9px] font-black uppercase">
                                        {{ $hq->catalog->name ?? __('No Catalog') }}
                                    </span>
                                </td>
                                <td class="px-6 py-4 text-xs text-gray-500 truncate max-w-xs">
                                    {{ $hq->delivery_address }}
                                </td>
                                <td class="px-6 py-4 text-right">
                                    <div class="flex justify-end gap-3">
                                        {{-- Fulfills requirement: Create branch directly for this HQ --}}
                                        <a href="{{ route('companys.create', ['parent_id' => $hq->id]) }}"
                                            class="text-[10px] font-black uppercase text-green-600 hover:underline">
                                            {{ __('Add Branch') }}
                                        </a>
                                        <a href="{{ route('companys.edit', $hq) }}"
                                            class="text-[10px] font-black uppercase text-blue-600 hover:underline">
                                            {{ __('Manage') }}
                                        </a>
                                    </div>
                                </td>
                            </tr>

                            {{-- Branch Sub-Rows [Addendum 3.c] --}}
                            @foreach ($hq->branches as $branch)
                                <tr>
                                    <td class="px-6 py-3 pl-16">
                                        <div class="flex items-center gap-2 text-gray-400 italic">
                                            <span>â†³</span>
                                            <div class="flex flex-col">
                                                <span
                                                    class="text-xs font-bold text-gray-700">{{ $branch->company_name }}</span>
                                                <span
                                                    class="text-[9px] font-mono uppercase tracking-tighter">{{ $branch->branch_code }}</span>
                                            </div>
                                        </div>
                                    </td>
                                    <td class="px-6 py-3">
                                        @if ($branch->catalog_id)
                                            <span
                                                class="px-2 py-1 rounded-full bg-gray-100 text-gray-600 text-[9px] font-black uppercase">
                                                {{ $branch->catalog->name }}
                                            </span>
                                        @else
                                            <span class="text-[9px] text-gray-400 font-bold italic uppercase">
                                                {{ __('Inherited: ') }} {{ $hq->catalog->name ?? 'None' }}
                                            </span>
                                        @endif
                                    </td>
                                    <td class="px-6 py-3 text-[10px] text-gray-400">
                                        {{ $branch->city }}, {{ $branch->state }}
                                    </td>
                                    <td class="px-6 py-3 text-right">
                                        <a href="{{ route('companys.edit', $branch) }}"
                                            class="text-[10px] font-black uppercase text-gray-400 hover:text-blue-600">{{ __('Edit Branch') }}</a>
                                    </td>
                                </tr>
                            @endforeach
                        @endforeach
                    </tbody>
                </table>
                <div class="p-6 border-t border-gray-100">
                    {{ $companys->links() }}
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/companys/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('Manage Business Entity') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-4xl mx-auto sm:px-6 lg:px-8">
            <form method="POST" action="{{ route('companys.update', $company) }}"
                class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100 p-8 space-y-10">
                @csrf
                @method('PUT')

                {{-- IMMUTABLE IDENTITY SECTION [Addendum 1.d, 3.c] --}}
                <div class="p-6 bg-gray-50 rounded-2xl border border-gray-100">
                    <label
                        class="text-[10px] uppercase font-black text-gray-500 mb-4 block underline decoration-gray-200 underline-offset-4">{{ __('System Identity (Locked)') }}</label>
                    <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                        <div>
                            <x-input-label :value="__('Registered Name')" class="text-[9px] uppercase font-black text-gray-400" />
                            <div class="mt-1 text-sm font-black text-gray-800 uppercase">{{ $company->company_name }}
                            </div>
                            <p class="mt-2 text-[8px] text-blue-400 italic uppercase">
                                {{ __('Contact Admin to change legal identity.') }}</p>
                        </div>
                        <div>
                            @if (is_null($company->parent_id))
                                <x-input-label :value="__('HQ Company Code')"
                                    class="text-[9px] uppercase font-black text-gray-400" />
                                <div class="mt-1 font-mono text-sm font-black text-blue-600">
                                    {{ $company->company_code }}</div>
                            @else
                                <x-input-label :value="__('Branch Identification Code')"
                                    class="text-[9px] uppercase font-black text-gray-400" />
                                <div class="mt-1 font-mono text-sm font-black text-blue-600">{{ $company->branch_code }}
                                </div>
                            @endif
                        </div>
                    </div>
                </div>

                {{-- EDITABLE BUSINESS DATA --}}
                <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                    <div>
                        <x-input-label for="company_reg_no" :value="__('SSM Registration No')"
                            class="text-[10px] uppercase font-black" />
                        <x-text-input id="company_reg_no" name="company_reg_no" type="text" class="mt-1 block w-full"
                            :value="old('company_reg_no', $company->company_reg_no)" />
                    </div>
                    <div>
                        <x-input-label for="catalog_id" :value="__('Catalog Whitelist Assignment')" class="text-[10px] uppercase font-black" />
                        <select name="catalog_id" id="catalog_id"
                            class="mt-1 block w-full border-gray-300 rounded-xl text-sm focus:ring-blue-500">
                            <option value="">
                                {{ $company->parent_id ? __('-- Inherit from Headquarters --') : __('-- No Catalog --') }}
                            </option>
                            @foreach ($catalogs as $catalog)
                                <option value="{{ $catalog->id }}"
                                    {{ old('catalog_id', $company->catalog_id) == $catalog->id ? 'selected' : '' }}>
                                    {{ $catalog->name }}</option>
                            @endforeach
                        </select>
                    </div>
                </div>

                {{-- LOGISTICS & PIC --}}
                <div class="space-y-6 pt-6 border-t border-gray-50">
                    <div class="text-[10px] uppercase font-black text-gray-400 tracking-widest">
                        {{ __('Contact person & Fulfillment') }}</div>
                    <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                        <div>
                            <x-input-label for="pic_name" :value="__('PIC Full Name')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="pic_name" name="pic_name" type="text" class="mt-1 block w-full"
                                :value="old('pic_name', $company->pic_name)" />
                        </div>
                        <div>
                            <x-input-label for="pic_phone" :value="__('PIC Contact Number')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="pic_phone" name="pic_phone" type="text" class="mt-1 block w-full"
                                :value="old('pic_phone', $company->pic_phone)" />
                        </div>
                    </div>
                    <div>
                        <x-input-label for="delivery_address" :value="__('Fulfillment Delivery Address')"
                            class="text-[10px] uppercase font-black" />
                        <textarea id="delivery_address" name="delivery_address"
                            class="mt-1 block w-full border-gray-300 rounded-xl text-sm focus:ring-blue-500" required>{{ old('delivery_address', $company->delivery_address) }}</textarea>
                    </div>
                    <div class="grid grid-cols-2 md:grid-cols-4 gap-4">
                        <div>
                            <x-input-label for="postal_code" :value="__('Postcode')"
                                class="text-[10px] uppercase font-black" />
                            <x-text-input id="postal_code" name="postal_code" type="text" class="mt-1 block w-full"
                                :value="old('postal_code', $company->postal_code)" />
                        </div>
                        <div class="col-span-1 md:col-span-2">
                            <x-input-label for="city" :value="__('City')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="city" name="city" type="text" class="mt-1 block w-full"
                                :value="old('city', $company->city)" />
                        </div>
                        <div>
                            <x-input-label for="state" :value="__('State')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="state" name="state" type="text" class="mt-1 block w-full"
                                :value="old('state', $company->state)" />
                        </div>
                    </div>
                </div>

                <div class="flex justify-end gap-4 pt-6">
                    <a href="{{ route('companys.index') }}"
                        class="text-xs font-black uppercase text-gray-400 py-3">{{ __('Cancel') }}</a>
                    <x-primary-button
                        class="bg-blue-600 hover:bg-blue-700 py-3 px-12 rounded-2xl text-[10px] font-black uppercase">
                        {{ __('Update Business Entity') }}
                    </x-primary-button>
                </div>
            </form>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/companys/create.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ $preselectedParent ? __('Add Branch to ') . $preselectedParent->company_name : __('Register New Business') }}
        </h2>
    </x-slot>

    <div class="py-12" x-data="{
        type: '{{ $preselectedParent ? 'branch' : old('entity_type', 'hq') }}',
        parentId: '{{ $preselectedParent->id ?? old('parent_id') }}'
    }">
        <div class="max-w-4xl mx-auto sm:px-6 lg:px-8">
            <form method="POST" action="{{ route('companys.store') }}"
                class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100 p-8 space-y-10">
                @csrf

                {{-- HIERARCHY SETUP --}}
                <div class="p-6 bg-gray-50 rounded-2xl border border-gray-100">
                    <label
                        class="text-[10px] uppercase font-black text-gray-400 mb-4 block tracking-widest">{{ __('Entity Relationship') }}</label>
                    <div class="flex items-center gap-8 mb-6">
                        <label class="inline-flex items-center cursor-pointer">
                            <input type="radio" name="entity_type" value="hq" x-model="type"
                                class="w-4 h-4 text-blue-600 border-gray-300"
                                @if ($preselectedParent) disabled @endif>
                            <span
                                class="ml-2 text-xs font-black text-gray-700 uppercase">{{ __('Main HQ Company') }}</span>
                        </label>
                        <label class="inline-flex items-center cursor-pointer">
                            <input type="radio" name="entity_type" value="branch" x-model="type"
                                class="w-4 h-4 text-blue-600 border-gray-300">
                            <span
                                class="ml-2 text-xs font-black text-gray-700 uppercase">{{ __('Branch Office') }}</span>
                        </label>
                    </div>

                    <div x-show="type === 'branch'" x-transition class="space-y-2">
                        <x-input-label for="parent_id" :value="__('Parent Headquarters')"
                            class="text-[10px] font-black uppercase text-blue-600" />
                        <select name="parent_id" id="parent_id" x-model="parentId" :required="type === 'branch'"
                            class="w-full border-gray-300 rounded-xl shadow-sm text-sm">
                            <option value="">{{ __('-- Choose Parent HQ --') }}</option>
                            @foreach ($hqs as $hq)
                                <option value="{{ $hq->id }}">{{ $hq->company_name }} ({{ $hq->company_code }})
                                </option>
                            @endforeach
                        </select>
                    </div>
                </div>

                {{-- IDENTITY & CODES --}}
                <div class="space-y-6">
                    <div
                        class="text-[10px] uppercase font-black text-gray-400 tracking-widest border-b border-gray-50 pb-2">
                        {{ __('Business Identity') }}</div>
                    <div>
                        <x-input-label for="company_name" :value="__('Registered Business Name')" class="text-[10px] uppercase font-black" />
                        <x-text-input id="company_name" name="company_name" type="text"
                            class="mt-1 block w-full font-bold" :value="old('company_name')" required />
                    </div>

                    <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                        <div x-show="type === 'hq'" x-transition>
                            <x-input-label for="company_code" :value="__('HQ Company Code')"
                                class="text-[10px] uppercase font-black text-blue-600" />
                            <x-text-input id="company_code" name="company_code" type="text"
                                class="mt-1 block w-full font-mono uppercase" placeholder="MA-XXXX" :value="old('company_code')"
                                x-bind:required="type === 'hq'" />
                        </div>
                        <div x-show="type === 'branch'" x-transition>
                            <x-input-label for="branch_code" :value="__('Branch Identification Code')"
                                class="text-[10px] uppercase font-black text-blue-600" />
                            <x-text-input id="branch_code" name="branch_code" type="text"
                                class="mt-1 block w-full font-mono uppercase" placeholder="BR-XXXX" :value="old('branch_code')"
                                x-bind:required="type === 'branch'" />
                        </div>
                        <div>
                            <x-input-label for="company_reg_no" :value="__('SSM Registration No')"
                                class="text-[10px] uppercase font-black" />
                            <x-text-input id="company_reg_no" name="company_reg_no" type="text"
                                class="mt-1 block w-full" :value="old('company_reg_no')" />
                        </div>
                    </div>
                </div>

                {{-- LOGISTICS & PIC --}}
                <div class="space-y-6">
                    <div
                        class="text-[10px] uppercase font-black text-gray-400 tracking-widest border-b border-gray-50 pb-2">
                        {{ __('Logistics & Contact Person') }}</div>
                    <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                        <div>
                            <x-input-label for="pic_name" :value="__('PIC Full Name')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="pic_name" name="pic_name" type="text" class="mt-1 block w-full"
                                :value="old('pic_name')" />
                        </div>
                        <div>
                            <x-input-label for="pic_phone" :value="__('PIC Phone Number')"
                                class="text-[10px] uppercase font-black" />
                            <x-text-input id="pic_phone" name="pic_phone" type="text" class="mt-1 block w-full"
                                :value="old('pic_phone')" />
                        </div>
                    </div>
                    <div>
                        <x-input-label for="delivery_address" :value="__('Default Delivery Address')"
                            class="text-[10px] uppercase font-black" />
                        <textarea id="delivery_address" name="delivery_address"
                            class="mt-1 block w-full border-gray-300 rounded-xl text-sm focus:ring-blue-500" required>{{ old('delivery_address') }}</textarea>
                    </div>
                    <div class="grid grid-cols-2 md:grid-cols-4 gap-4">
                        <div class="col-span-1">
                            <x-input-label for="postal_code" :value="__('Postcode')"
                                class="text-[10px] uppercase font-black" />
                            <x-text-input id="postal_code" name="postal_code" type="text" class="mt-1 block w-full"
                                :value="old('postal_code')" />
                        </div>
                        <div class="col-span-1 md:col-span-2">
                            <x-input-label for="city" :value="__('City')" class="text-[10px] uppercase font-black" />
                            <x-text-input id="city" name="city" type="text" class="mt-1 block w-full"
                                :value="old('city')" />
                        </div>
                        <div class="col-span-2 md:col-span-1">
                            <x-input-label for="state" :value="__('State')"
                                class="text-[10px] uppercase font-black" />
                            <x-text-input id="state" name="state" type="text" class="mt-1 block w-full"
                                :value="old('state')" />
                        </div>
                    </div>
                </div>

                {{-- CATALOG POLICY --}}
                <div class="p-8 bg-gray-900 rounded-[2rem] shadow-xl text-white">
                    <x-input-label for="catalog_id" :value="__('Assign Product Whitelist Folder')"
                        class="text-blue-400 text-[10px] font-black uppercase mb-2" />
                    <select name="catalog_id" id="catalog_id"
                        class="w-full bg-gray-800 border-gray-700 text-white rounded-xl text-sm focus:ring-blue-500">
                        <option value="">{{ __('Inherit Parent Catalog By Default') }} [8.a.2]</option>
                        @foreach ($catalogs as $catalog)
                            <option value="{{ $catalog->id }}"
                                {{ old('catalog_id') == $catalog->id ? 'selected' : '' }}>{{ $catalog->name }}
                            </option>
                        @endforeach
                    </select>
                </div>

                <div class="flex justify-end gap-4">
                    <a href="{{ route('companys.index') }}"
                        class="text-xs font-black uppercase text-gray-400 py-4">{{ __('Cancel') }}</a>
                    <x-primary-button
                        class="bg-blue-600 hover:bg-blue-700 py-4 px-12 rounded-2xl text-[10px] font-black uppercase">
                        {{ __('Finalize Registration') }}
                    </x-primary-button>
                </div>
            </form>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/catalogs/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('Catalog Management') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            @if (session('success'))
                <div class="mb-4 p-4 bg-green-100 text-green-700 rounded-lg">
                    {{ session('success') }}
                </div>
            @endif
            @if (session('error'))
                <div class="mb-4 p-4 bg-red-100 text-red-700 rounded-lg">
                    {{ session('error') }}
                </div>
            @endif

            <div class="mb-6">
                <form action="{{ route('catalogs.index') }}" method="GET">
                    <x-filter-toolbar :placeholder="__('Search catalog folders...')" />
                </form>
            </div>

            @can('create_catalogs')
                <div class="flex justify-end mb-4">
                    <a href="{{ route('catalogs.create') }}"
                        class="bg-blue-600 text-white px-4 py-2 rounded hover:bg-blue-700 text-sm">
                        + {{ __('Create New Catalog') }}
                    </a>
                </div>
            @endcan

            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg">
                <table class="min-w-full divide-y divide-gray-200">
                    <thead class="bg-gray-50">
                        <tr>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase">
                                {{ __('Catalog Name') }}</th>
                            <th class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase">
                                {{ __('Items Whitelisted') }}</th>
                            <th class="px-6 py-3 text-right text-xs font-medium text-gray-500 uppercase">
                                {{ __('Actions') }}</th>
                        </tr>
                    </thead>
                    <tbody class="bg-white divide-y divide-gray-200">
                        @foreach ($catalogs as $catalog)
                            <tr
                                class="transition-colors {{ $catalog->status === 'deactive' ? 'bg-red-50 hover:bg-red-100' : 'hover:bg-gray-50' }}">
                                <td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-900">
                                    {{ $catalog->name }}
                                    @if ($catalog->status === 'deactive')
                                        <span
                                            class="ml-2 px-2 py-0.5 bg-red-600 text-white text-[9px] font-black uppercase rounded">{{ __('Deactive') }}</span>
                                    @endif
                                </td>
                                <td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">
                                    <span
                                        class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-indigo-100 text-indigo-800">
                                        {{ $catalog->items_count }} {{ __('Items') }}
                                    </span>
                                </td>
                                <td class="px-6 py-4 whitespace-nowrap text-right text-sm font-medium">
                                    @can('edit_catalogs')
                                        <a href="{{ route('catalogs.edit', $catalog->id) }}"
                                            class="text-indigo-600 hover:text-indigo-900 mr-4">
                                            {{ __('Manage Whitelist') }}
                                        </a>
                                    @endcan
                                </td>
                            </tr>
                        @endforeach
                    </tbody>
                </table>
                <div class="p-4">
                    {{ $catalogs->links() }}
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/catalogs/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('📂 Edit Folder: ') . $catalog->name }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-4xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white p-8 shadow-xl sm:rounded-2xl border border-gray-100">

                <form action="{{ route('catalogs.update', $catalog) }}" method="POST" class="space-y-8">
                    @csrf
                    @method('PUT')

                    <div>
                        <x-input-label for="name" :value="__('Catalog Folder Name')" />
                        <x-text-input id="name" name="name" type="text" class="mt-1 block w-full"
                            :value="old('name', $catalog->name)" required />
                        <p class="text-[10px] text-gray-500 mt-2 italic uppercase font-bold">
                            {{ __('Changing this name affects all linked customers [Section 3.a.1].') }}</p>
                    </div>

                    <div class="pt-6 border-t border-gray-100">
                        <h3 class="text-sm font-black text-gray-800 uppercase tracking-widest mb-2">
                            {{ __('Item Whitelist Selection') }}</h3>
                        <p class="text-xs text-gray-500 mb-6">
                            {{ __('Checked items will be visible to customers assigned to this folder.') }}</p>

                        @if ($items->isEmpty())
                            <div
                                class="p-6 bg-amber-50 rounded-xl border border-amber-100 text-amber-700 text-xs font-bold text-center uppercase">
                                {{ __('No items found. Please create items in Product Management first.') }}
                            </div>
                        @else
                            <div
                                class="grid grid-cols-1 md:grid-cols-2 gap-4 max-h-[400px] overflow-y-auto pr-2 custom-scrollbar">
                                @foreach ($items as $item)
                                    <label
                                        class="relative flex items-center p-4 border rounded-xl hover:bg-gray-50 transition shadow-sm cursor-pointer {{ in_array($item->id, $assignedItemIds) ? 'bg-blue-50 border-blue-200' : 'bg-white border-gray-100' }}">
                                        <input name="items[]" value="{{ $item->id }}" type="checkbox"
                                            class="focus:ring-blue-500 h-5 w-5 text-blue-600 border-gray-300 rounded-lg mr-4"
                                            {{ in_array($item->id, $assignedItemIds) ? 'checked' : '' }}>
                                        <div class="flex-1">
                                            <div class="text-xs font-black text-blue-700 uppercase">{{ $item->sku }}
                                            </div>
                                            <div class="text-sm font-bold text-gray-800 leading-tight">
                                                {{ $item->name }}</div>
                                            <div class="text-[10px] font-mono text-gray-500 mt-1">RM
                                                {{ number_format($item->price, 2) }}</div>
                                        </div>
                                    </label>
                                @endforeach
                            </div>
                        @endif
                    </div>

                    <div class="flex items-center justify-end pt-8 border-t border-gray-100">
                        <a href="{{ route('catalogs.index') }}"
                            class="text-sm text-gray-600 hover:text-gray-900 underline mr-6">{{ __('Cancel') }}</a>
                        <x-primary-button
                            class="bg-blue-700 hover:bg-blue-800">{{ __('Save Folder & Whitelist') }}</x-primary-button>
                    </div>
                </form>

                {{-- Lifecycle Section --}}
                <div
                    class="mt-16 bg-gray-800 p-8 rounded-3xl text-white flex flex-col md:flex-row justify-between items-center gap-8 shadow-2xl">
                    <div>
                        <h4 class="font-black uppercase text-sm tracking-widest text-amber-400">
                            {{ __('Catalog Lifecycle') }}</h4>
                        <p class="text-[10px] text-gray-400 mt-2">
                            {{ __('Deactivating a folder hides ALL assigned products from linked customers immediately.') }}
                        </p>
                    </div>
                    <div class="flex gap-3">
                        <form action="{{ route('catalogs.update', $catalog) }}" method="POST">
                            @csrf @method('PUT')
                            <input type="hidden" name="name" value="{{ $catalog->name }}">

                            @if ($catalog->status === 'active')
                                <input type="hidden" name="status" value="deactive">
                                <button type="submit"
                                    class="px-6 py-2 bg-amber-500 hover:bg-amber-600 rounded-xl text-xs font-black uppercase transition shadow-md">
                                    {{ __('⛔ Deactivate Folder') }}
                                </button>
                            @else
                                <input type="hidden" name="status" value="active">
                                <button type="submit"
                                    class="px-6 py-2 bg-green-600 hover:bg-green-700 rounded-xl text-xs font-black uppercase transition shadow-md">
                                    {{ __('✅ Reactivate Folder') }}
                                </button>
                            @endif
                        </form>

                        @if ($catalog->canBeDeleted())
                            <form action="{{ route('catalogs.destroy', $catalog) }}" method="POST">
                                @csrf @method('DELETE')
                                <button type="submit"
                                    class="bg-red-600 hover:bg-red-700 text-white px-6 py-2 rounded-xl text-xs font-black uppercase transition shadow-md">
                                    {{ __('🔥 Hard Delete') }}
                                </button>
                            </form>
                        @endif
                    </div>
                </div>

            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/catalogs/create.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">{{ __('Create New Catalog') }}</h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6">
                <form method="POST" action="{{ route('catalogs.store') }}">
                    @csrf
                    <div>
                        <x-input-label for="name" :value="__('Catalog Name')" />
                        <x-text-input id="name" name="name" type="text" class="mt-1 block w-full md:w-1/2"
                            required autofocus />
                        <x-input-error :messages="$errors->get('name')" class="mt-2" />
                    </div>

                    <div class="flex items-center mt-6">
                        <x-primary-button>{{ __('Create Catalog') }}</x-primary-button>
                        <a href="{{ route('catalogs.index') }}"
                            class="ml-4 text-sm text-gray-600 underline">{{ __('Cancel') }}</a>
                    </div>
                </form>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/items/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase">
            {{ __('Item Master List') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">
            <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            @can('create_items')
                <a href="{{ route('items.create') }}" class="bg-blue-600 hover:bg-blue-700 text-white px-6 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-lg shadow-blue-100">
                    {{ __('+ New Item') }}
                </a>
            @endcan
        </div>
            {{-- SEARCH TOOLBAR --}}
            <div class="bg-white p-6 rounded-[2rem] border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('items.index') }}" class="flex gap-4">
                    <div class="flex-1 relative">
                        <x-text-input name="search" value="{{ request('search') }}" placeholder="{{ __('Search by SKU or Display Name...') }}" class="w-full pl-10 pr-4 py-3 rounded-2xl border-gray-100 focus:ring-blue-500" />
                        <svg class="w-5 h-5 text-gray-300 absolute left-3 top-3.5" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" /></svg>
                    </div>
                    <button type="submit" class="bg-gray-900 hover:bg-black text-white px-8 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-md">
                        {{ __('Filter') }}
                    </button>
                </form>
            </div>

            {{-- MASTER LIST TABLE --}}
            <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('SKU / Identity') }}</th>
                            <th class="px-6 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Linked Catalogs') }}</th>
                            {{-- ARCHITECTURE FIX: Swapped Price for Status [Turn Context] --}}
                            <th class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Listing Status') }}</th>
                            <th class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Management') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50 bg-white">
                        @foreach ($items as $item)
                            <tr class="hover:bg-gray-50/50 transition-colors">
                                <td class="px-8 py-5">
                                    <div class="flex items-center gap-4">
                                        @if($item->image_path)
                                            <img src="{{ asset('storage/'.$item->image_path) }}" class="w-10 h-10 rounded-xl object-cover border border-gray-100">
                                        @else
                                            <div class="w-10 h-10 bg-gray-50 rounded-xl flex items-center justify-center text-[8px] font-black text-gray-300 uppercase">{{ __('No img') }}</div>
                                        @endif
                                        <div class="flex flex-col">
                                            <span class="text-sm font-black text-gray-800 uppercase leading-tight">{{ $item->name }}</span>
                                            <span class="text-[10px] font-mono text-blue-500 font-bold tracking-tighter uppercase">{{ $item->sku }}</span>
                                        </div>
                                    </div>
                                </td>
                                <td class="px-6 py-5">
                                    <div class="flex flex-wrap gap-1">
                                        @forelse($item->catalogs as $catalog)
                                            <span class="px-2 py-0.5 bg-indigo-50 text-indigo-600 rounded-md text-[8px] font-black uppercase border border-indigo-100">
                                                {{ $catalog->name }}
                                            </span>
                                        @empty
                                            <span class="text-[9px] text-gray-300 italic uppercase">{{ __('Not Whitelisted') }}</span>
                                        @endforelse
                                    </div>
                                </td>
                                {{-- STATUS BADGE: Fulfills UI Requirement [Turn Context] --}}
                                <td class="px-6 py-5 text-center">
                                    @php
                                        $hasBaseUnit = $item->activeUoms->contains('rate_qty', 1);
                                        $displayStatus = ($item->status === 'active' && $hasBaseUnit) ? 'Active' : 'inactive';
                                    @endphp
                                    
                                    <span class="px-3 py-1 rounded-full text-[9px] font-black uppercase border shadow-sm
                                        {{ $displayStatus === 'Active' ? 'bg-green-50 text-green-700 border-green-200' : 'bg-red-50 text-red-700 border-red-200' }}">
                                        {{ $displayStatus }}
                                    </span>

                                    @if($item->status === 'active' && !$hasBaseUnit)
                                        <p class="text-[8px] text-red-400 font-black uppercase italic mt-1" title="{{ __('System locked: Missing Rate Qty 1') }}">
                                            {{ __('Invalid Config') }}
                                        </p>
                                    @endif
                                </td>
                                <td class="px-8 py-5 text-right">
                                    <div class="flex justify-end gap-2">
                                        @can('edit_items')
                                            <a href="{{ route('items.edit', $item) }}" class="p-2 bg-white border border-gray-200 rounded-xl text-gray-400 hover:text-blue-600 hover:border-blue-100 transition shadow-sm">
                                                <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5"><path d="M15.232 5.232l3.536 3.536m-2.036-5.036a2.5 2.5 0 113.536 3.536L6.5 21.036H3v-3.572L16.732 3.732z" /></svg>
                                            </a>
                                        @endcan
                                    </div>
                                </td>
                            </tr>
                        @endforeach
                    </tbody>
                </table>
            </div>

            <div class="mt-6">
                {{ $items->links() }}
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/items/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Edit Product Entity') }}: <span class="text-blue-600">{{ $item->sku }}</span>
            </h2>
            <a href="{{ route('items.index') }}"
                class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                &larr; {{ __('Back to Registry') }}
            </a>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">

            @if ($errors->any())
                <div class="alert alert-danger">
                    <ul>
                        @foreach ($errors->all() as $error)
                            <li>{{ $error }}</li>
                        @endforeach
                    </ul>
                </div>
            @endif

            {{-- ARCHITECTURE GUARD: Transactional Integrity Warning [Backbone 3.c.1] --}}
            @if ($item->orderItems()->whereHas('order', fn($q) => $q->whereIn('status', ['approved', 'completed']))->exists())
                <div class="p-6 bg-amber-50 border border-amber-100 rounded-[2rem] flex gap-4 items-center">
                    <div
                        class="w-12 h-12 bg-white rounded-2xl flex items-center justify-center text-amber-500 shadow-sm">
                        <svg class="w-6 h-6" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                            stroke-width="2.5">
                            <path
                                d="M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z" />
                        </svg>
                    </div>
                    <div>
                        <h4 class="text-[11px] font-black uppercase text-amber-900 tracking-tight">
                            {{ __('Core Identity Lock Active') }}</h4>
                        <p class="text-[9px] font-bold text-amber-700 uppercase italic">
                            {{ __('Finalized transaction snapshots exist for this item. Identity modifications are restricted to maintain historical auditing integrity.') }}
                            [3.c.1, 4.b]</p>
                    </div>
                </div>
            @endif

            <form method="POST" action="{{ route('items.update', $item) }}" enctype="multipart/form-data"
                class="space-y-8">
                @csrf
                @method('PUT')

                <div class="grid grid-cols-1 lg:grid-cols-3 gap-8">

                    {{-- COLUMN 1: PRIMARY IDENTITY & WHITELISTING --}}
                    <div class="lg:col-span-2 space-y-8">

                        <div class="bg-white p-10 rounded-[2.5rem] border border-gray-100 shadow-sm">
                            <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                                <div>
                                    <x-input-label for="name" :value="__('Display Name')"
                                        class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                                    <x-text-input id="name" name="name" type="text"
                                        class="block w-full font-bold uppercase" :value="old('name', $item->name)" required />
                                </div>
                                <div>
                                    <x-input-label for="sku" :value="__('System SKU')"
                                        class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                                    <x-text-input id="sku" name="sku" type="text"
                                        class="block w-full font-mono font-black text-blue-600 uppercase"
                                        :value="old('sku', $item->sku)" required />
                                </div>
                                <div class="md:col-span-2">
                                    <x-input-label for="description" :value="__('Specifications')"
                                        class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                                    <textarea id="description" name="description" rows="3"
                                        class="block w-full border-gray-100 rounded-2xl text-xs font-bold uppercase focus:ring-blue-500">{{ old('description', $item->description) }}</textarea>
                                </div>
                            </div>
                        </div>

                        <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                            {{-- CATEGORIZATION SEARCH --}}
                            <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm"
                                x-data="{ search: '', count: {{ (int) $item->categories->count() }} }">
                                <h3 class="text-[10px] font-black uppercase text-gray-400 tracking-widest mb-4">
                                    {{ __('Categorization') }} <span class="ml-2 text-blue-500" x-text="count"></span>
                                </h3>
                                <input type="text" x-model="search" placeholder="{{ __('Filter...') }}"
                                    class="w-full mb-4 bg-gray-50 border-gray-100 rounded-2xl text-[10px] font-black uppercase pl-4">
                                <div class="space-y-2 max-h-48 overflow-y-auto pr-2 custom-scrollbar">
                                    @php $itemCatIds = $item->categories->pluck('id')->toArray(); @endphp
                                    @forelse($categories as $category)
                                        <label
                                            x-show="'{{ strtoupper($category->name) }}'.includes(search.toUpperCase())"
                                            class="flex items-center p-2 rounded-xl hover:bg-gray-50 cursor-pointer">
                                            <input type="checkbox" name="categories[]" value="{{ $category->id }}"
                                                class="rounded border-gray-300 text-blue-600"
                                                @if (in_array($category->id, $itemCatIds)) checked @endif
                                                x-on:change="count = $event.target.checked ? count + 1 : count - 1">
                                            <span
                                                class="ml-3 text-[11px] font-black text-gray-700 uppercase">{{ $category->name }}</span>
                                        </label>
                                    @empty
                                        <p class="text-[9px] font-black text-gray-300 uppercase italic">
                                            {{ __('No Groups Defined') }}</p>
                                    @endforelse
                                </div>
                            </div>

                            {{-- CATALOG WHITELIST SEARCH [Backbone 3.a.1] --}}
                            <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm"
                                x-data="{ search: '', count: {{ (int) $item->catalogs->count() }} }">
                                <h3 class="text-[10px] font-black uppercase text-gray-400 tracking-widest mb-4">
                                    {{ __('Catalog Whitelist') }} <span class="ml-2 text-indigo-500"
                                        x-text="count"></span></h3>
                                <input type="text" x-model="search" placeholder="{{ __('Filter...') }}"
                                    class="w-full mb-4 bg-gray-50 border-gray-100 rounded-2xl text-[10px] font-black uppercase pl-4">
                                <div class="space-y-2 max-h-48 overflow-y-auto pr-2 custom-scrollbar">
                                    @php $itemCatalogIds = $item->catalogs->pluck('id')->toArray(); @endphp
                                    @forelse($catalogs as $catalog)
                                        <label
                                            x-show="'{{ strtoupper($catalog->name) }}'.includes(search.toUpperCase())"
                                            class="flex items-center p-2 rounded-xl hover:bg-gray-50 cursor-pointer">
                                            <input type="checkbox" name="catalogs[]" value="{{ $catalog->id }}"
                                                class="rounded border-gray-300 text-indigo-600"
                                                @if (in_array($catalog->id, $itemCatalogIds)) checked @endif
                                                x-on:change="count = $event.target.checked ? count + 1 : count - 1">
                                            <span
                                                class="ml-3 text-[11px] font-black text-gray-700 uppercase">{{ $catalog->name }}</span>
                                        </label>
                                    @empty
                                        <p class="text-[9px] font-black text-gray-300 uppercase italic">
                                            {{ __('No Catalogs Defined') }}</p>
                                    @endforelse
                                </div>
                            </div>
                        </div>
                    </div>

                    {{-- COLUMN 2: STATUS & MEDIA --}}
                    <div class="space-y-8">
                        <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm">
                            <div class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                                {{ __('Operational Status') }}</div>
                            <select name="status"
                                class="w-full border-gray-100 rounded-2xl text-xs font-black uppercase text-gray-700 focus:ring-blue-500 shadow-sm">
                                <option value="active" @if ($item->status === 'active') selected @endif>
                                    {{ __('Active & Orderable') }}</option>
                                <option value="inactive" @if ($item->status === 'inactive') selected @endif>
                                    {{ __('Deactivated (Hold)') }}</option>
                            </select>
                        </div>

                        <div class="bg-white p-8 rounded-[2.5rem] border border-gray-100 shadow-sm">
                            <div class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                                {{ __('Media') }}</div>
                            <div class="flex flex-col items-center gap-6">
                                @if ($item->image_path)
                                    <img src="{{ asset('storage/' . $item->image_path) }}"
                                        class="w-full aspect-square rounded-[2rem] object-cover border border-gray-50 shadow-inner">
                                @endif
                                <input type="file" name="image"
                                    class="text-[9px] font-black uppercase text-gray-400">
                            </div>
                        </div>
                    </div>
                </div>

                {{-- REFACTORED: Unit of Measure (UOM) Configurations container [CRUD FIX] --}}
                <div class="bg-white p-10 rounded-[2.5rem] border border-gray-100 shadow-sm" x-data="{
                    uoms: {{ $item->uoms->map(
                            fn($u) => [
                                'id' => $u->id,
                                'uom_name' => $u->uom_name,
                                'rate_qty' => $u->rate_qty,
                                'price' => $u->price,
                                'status' => $u->status,
                            ],
                        )->toJson() }},
                    addUom() {
                        this.uoms.push({ id: null, uom_name: '', rate_qty: 1, price: 0.00, status: 'active' });
                    },
                    removeUom(index) {
                        this.uoms.splice(index, 1);
                    }
                }">

                    <div class="flex justify-between items-center mb-10">
                        <div>
                            <h3
                                class="text-[10px] font-black uppercase text-gray-400 tracking-widest flex items-center gap-2">
                                <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                                    stroke-width="2.5">
                                    <path d="M20 7l-8-4-8 4m16 0l-8 4m8-4v10l-8 4m0-10L4 7m8 4v10M4 7v10l8 4" />
                                </svg>
                                {{ __('Unit of Measure (UOM) Configurations') }}
                            </h3>
                            <p class="text-[8px] font-bold text-gray-300 uppercase italic mt-1">
                                {{ __('Pricing source for all orders.') }} [Addendum 5.a]</p>
                        </div>
                        <button type="button" x-on:click="addUom()"
                            class="bg-blue-50 text-blue-600 px-6 py-2 rounded-xl text-[9px] font-black uppercase hover:bg-blue-100 transition">
                            {{ __('+ Add Packaging Tier') }}
                        </button>
                    </div>

                    <div class="overflow-x-auto">
                        <table class="min-w-full divide-y divide-gray-50">
                            <thead>
                                <tr class="text-[9px] font-black text-gray-400 uppercase tracking-tighter">
                                    <th class="px-4 py-4 text-left">{{ __('Unit Name') }}</th>
                                    <th class="px-4 py-4 text-center">{{ __('Rate (Base 1)') }}</th>
                                    <th class="px-4 py-4 text-right">{{ __('Internal Price (RM)') }}</th>
                                    <th class="px-4 py-4 text-center">{{ __('Status') }}</th>
                                    <th class="px-4 py-4 text-right"></th>
                                </tr>
                            </thead>
                            <tbody class="divide-y divide-gray-50">
                                <template x-for="(uom, index) in uoms" :key="index">
                                    <tr class="group hover:bg-gray-50/50 transition-colors">
                                        <td class="px-2 py-4">
                                            <input type="hidden" :name="'uoms[' + index + '][id]'" x-model="uom.id">
                                            <input type="text" :name="'uoms[' + index + '][uom_name]'"
                                                x-model="uom.uom_name" required
                                                class="w-full border-gray-100 rounded-xl text-[11px] font-black uppercase focus:ring-blue-500">
                                        </td>
                                        <td class="px-2 py-4">
                                            <input type="number" :name="'uoms[' + index + '][rate_qty]'"
                                                x-model="uom.rate_qty" min="1" required
                                                class="w-24 mx-auto block border-gray-100 rounded-xl text-[11px] font-mono font-black text-blue-600 text-center">
                                        </td>
                                        <td class="px-2 py-4">
                                            <input type="number" :name="'uoms[' + index + '][price]'"
                                                x-model="uom.price" step="0.01" min="0" required
                                                class="w-32 ml-auto block border-gray-100 rounded-xl text-[11px] font-mono font-black text-right">
                                        </td>
                                        <td class="px-2 py-4">
                                            <select :name="'uoms[' + index + '][status]'" x-model="uom.status"
                                                class="w-full border-gray-100 rounded-xl text-[9px] font-black uppercase focus:ring-blue-500">
                                                <option value="active">{{ __('Active') }}</option>
                                                <option value="inactive">{{ __('Inactive') }}</option>
                                            </select>
                                            {{-- ARCHITECTURE STANDARD: Visible validation feedback --}}
                                            @error('uoms.*.status')
                                                <p class="text-[7px] text-red-500 mt-1 uppercase font-black">
                                                    {{ $message }}</p>
                                            @enderror
                                        </td>
                                        <td class="px-2 py-4 text-right">
                                            <button type="button" x-on:click="removeUom(index)"
                                                class="text-red-300 hover:text-red-500 transition-all p-2">
                                                <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24"
                                                    stroke="currentColor" stroke-width="2.5">
                                                    <path
                                                        d="M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16" />
                                                </svg>
                                            </button>
                                        </td>
                                    </tr>
                                </template>
                            </tbody>
                        </table>

                        <div x-show="uoms.length === 0"
                            class="py-12 text-center border-2 border-dashed border-gray-100 rounded-[2rem] bg-gray-50/30">
                            <p class="text-[9px] font-black text-gray-300 uppercase italic">
                                {{ __('No packaging units defined. This item will be suppressed from Catalogs until a valid unit is saved.') }}
                                [3.a.3]
                            </p>
                        </div>
                    </div>
                </div>

                <div class="flex items-center justify-end gap-6 pt-8">
                    <a href="{{ route('items.index') }}"
                        class="text-[10px] font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">{{ __('Discard Changes') }}</a>
                    <x-primary-button
                        class="bg-gray-900 hover:bg-black py-5 px-16 rounded-[2rem] shadow-xl shadow-gray-100 transition-all uppercase text-[11px] font-black tracking-[0.1em]">
                        {{ __('Save Product Configuration') }}
                    </x-primary-button>
                </div>
            </form>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/items/create.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('Register New Product') }}
        </h2>
    </x-slot>

    <div class="py-12" x-data="{
        uoms: [],
        addUom() {
            this.uoms.push({ uom_name: '', rate_qty: 1, price: 0, status: 'active' });
        },
        removeUom(index) {
            this.uoms.splice(index, 1);
        }
    }">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">

            <form method="POST" action="{{ route('items.store') }}" enctype="multipart/form-data" class="space-y-8">
                @csrf

                {{-- SECTION 1: MASTER ATTRIBUTES --}}
                <div
                    class="bg-white p-8 rounded-[2rem] border border-gray-100 shadow-sm grid grid-cols-1 md:grid-cols-3 gap-8">
                    <div class="md:col-span-2 space-y-6">
                        <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                            <div>
                                <x-input-label for="sku" :value="__('Product SKU')"
                                    class="text-[10px] font-black uppercase text-gray-400" />
                                <x-text-input id="sku" name="sku" type="text"
                                    class="mt-1 block w-full font-mono uppercase" :value="old('sku')" required />
                                <x-input-error :messages="$errors->get('sku')" class="mt-2" />
                            </div>
                            <div>
                                <x-input-label for="status" :value="__('Listing Status')"
                                    class="text-[10px] font-black uppercase text-gray-400" />
                                <select name="status"
                                    class="mt-1 block w-full rounded-xl border-gray-300 text-sm font-bold uppercase focus:ring-blue-500">
                                    <option value="active">{{ __('Active') }}</option>
                                    <option value="deactive">{{ __('Inactive') }}</option>
                                </select>
                                <p class="mt-2 text-[9px] text-amber-600 font-black uppercase italic">
                                    {{ __('Note: Status forced to Inactive if no UOM is added.') }}</p>
                            </div>
                        </div>

                        <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                            <div>
                                <x-input-label for="name" :value="__('Product Name')"
                                    class="text-[10px] font-black uppercase text-gray-400" />
                                <x-text-input id="name" name="name" type="text"
                                    class="mt-1 block w-full font-bold" :value="old('name')" required />
                            </div>
                        </div>

                        {{-- Universal Description: Fulfills Requirement --}}
                        <div>
                            <x-input-label for="description" :value="__('Product Description (Public)')"
                                class="text-[10px] font-black uppercase text-gray-400 mb-1" />
                            <textarea id="description" name="description" rows="3"
                                class="w-full border-gray-300 focus:border-indigo-500 focus:ring-indigo-500 rounded-xl shadow-sm text-sm"
                                placeholder="{{ __('Provide technical specs or context for customers...') }}">{{ old('description') }}</textarea>
                        </div>
                    </div>

                    {{-- Image Asset Management --}}
                    <div
                        class="bg-gray-50 p-6 rounded-[1.5rem] border border-gray-100 flex flex-col items-center justify-center text-center">
                        <div
                            class="w-32 h-32 bg-white rounded-xl flex items-center justify-center mb-4 border-2 border-dashed border-gray-200 text-gray-300">
                            <svg class="w-8 h-8" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                                <path
                                    d="M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z" />
                            </svg>
                        </div>
                        <input id="image" name="image" type="file"
                            class="text-[10px] text-gray-500 file:mr-4 file:py-2 file:px-4 file:rounded-full file:border-0 file:text-[10px] file:font-black file:bg-blue-50 file:text-blue-700 hover:file:bg-blue-100" />
                    </div>
                </div>

                {{-- SECTION 2: UNIT OF MEASURE (UOM) MANAGEMENT [Addendum 5.a] --}}
                <div class="bg-gray-900 rounded-[2.5rem] p-8 shadow-xl">
                    <div class="flex justify-between items-center mb-8">
                        <div>
                            <h3 class="text-xs font-black uppercase text-blue-400 tracking-widest">
                                {{ __('UOM Configurations (Mandatory)') }}</h3>
                            <p class="text-[10px] text-gray-500 mt-1 uppercase">
                                {{ __('Strict UOM Protocol: At least one active unit required for catalog visibility.') }}
                            </p>
                        </div>
                        <button type="button" @click="addUom()"
                            class="inline-flex items-center px-4 py-2 bg-blue-600 hover:bg-blue-700 text-white rounded-xl text-[10px] font-black uppercase transition shadow-lg shadow-blue-900">
                            {{ __('+ Add Packaging Unit') }}
                        </button>
                    </div>

                    <div class="space-y-4">
                        <template x-for="(uom, index) in uoms" :key="index">
                            <div
                                class="grid grid-cols-1 md:grid-cols-12 gap-4 p-5 bg-gray-800 rounded-2xl border border-gray-700 items-end transition-all">
                                <div class="md:col-span-4">
                                    <label
                                        class="text-[9px] font-black text-gray-500 uppercase mb-1 block">{{ __('Unit Name (e.g. Carton 24s)') }}</label>
                                    <input type="text" :name="'uoms[' + index + '][uom_name]'" x-model="uom.uom_name"
                                        required
                                        class="w-full bg-gray-900 border-gray-700 rounded-xl text-white text-sm focus:ring-blue-500">
                                </div>
                                <div class="md:col-span-2">
                                    <label
                                        class="text-[9px] font-black text-gray-500 uppercase mb-1 block">{{ __('Rate Qty') }}</label>
                                    <input type="number" :name="'uoms[' + index + '][rate_qty]'" x-model="uom.rate_qty"
                                        min="1" required
                                        class="w-full bg-gray-900 border-gray-700 rounded-xl text-white text-sm focus:ring-blue-500">
                                </div>
                                <div class="md:col-span-3">
                                    <label
                                        class="text-[9px] font-black text-blue-500 uppercase mb-1 block">{{ __('Staff Price (RM)') }}</label>
                                    <input type="number" step="0.01" :name="'uoms[' + index + '][price]'"
                                        x-model="uom.price" required
                                        class="w-full bg-gray-900 border-blue-900/50 rounded-xl text-white text-sm focus:ring-blue-500">
                                </div>
                                <div class="md:col-span-3 flex gap-2">
                                    <select :name="'uoms[' + index + '][status]'" x-model="uom.status"
                                        class="flex-1 rounded-xl text-[10px] font-black uppercase border-gray-700 bg-gray-900 focus:ring-blue-500"
                                        :class="uom.status === 'active' ? 'text-green-400' : 'text-red-400'">
                                        <option value="active">{{ __('Active') }}</option>
                                        <option value="inactive">{{ __('Inactive') }}</option>
                                    </select>
                                    <button type="button" @click="removeUom(index)"
                                        class="h-10 w-10 flex items-center justify-center bg-gray-700 hover:bg-red-600 rounded-xl text-white transition">
                                        <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                                            stroke-width="2.5">
                                            <path
                                                d="M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16" />
                                        </svg>
                                    </button>
                                </div>
                            </div>
                        </template>

                        <div x-show="uoms.length === 0"
                            class="py-10 border-2 border-dashed border-gray-800 rounded-[2rem] flex flex-col items-center justify-center">
                            <p class="text-[10px] font-black uppercase text-gray-600 tracking-widest">
                                {{ __('No packaging units defined') }}</p>
                        </div>
                    </div>
                </div>

                {{-- SECTION 3: ASSIGNMENTS (Categorization and Catalogs) --}}
                <div
                    class="bg-white p-8 rounded-[2rem] border border-gray-100 shadow-sm grid grid-cols-1 md:grid-cols-2 gap-8">
                    {{-- Categories [Backbone 3.a.3] --}}
                    <div>
                        <h3 class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                            {{ __('Categorization') }}</h3>
                        <div class="grid grid-cols-2 gap-3">
                            @foreach (\App\Models\Category::all() as $category)
                                <label
                                    class="flex items-center p-3 border border-gray-100 rounded-xl hover:bg-gray-50 transition cursor-pointer">
                                    <input type="checkbox" name="categories[]" value="{{ $category->id }}"
                                        class="rounded border-gray-300 text-blue-600">
                                    <span
                                        class="ml-2 text-[10px] font-black uppercase text-gray-600">{{ $category->name }}</span>
                                </label>
                            @endforeach
                        </div>
                    </div>

                    {{-- Catalog Whitelist Selection: Fulfills Requirement --}}
                    <div>
                        <h3 class="text-[10px] font-black uppercase text-blue-600 mb-6 tracking-widest">
                            {{ __('Catalog Visibility (Whitelisting)') }}</h3>
                        <div class="grid grid-cols-1 gap-3">
                            @foreach ($catalogs as $catalog)
                                <label
                                    class="flex items-center p-3 border border-blue-50 rounded-xl hover:bg-blue-50 transition cursor-pointer">
                                    <input type="checkbox" name="catalogs[]" value="{{ $catalog->id }}"
                                        class="rounded border-blue-300 text-blue-600">
                                    <div class="ml-3 flex flex-col">
                                        <span
                                            class="text-[10px] font-black uppercase text-blue-900">{{ $catalog->name }}</span>
                                        <span
                                            class="text-[8px] text-blue-400 font-bold uppercase tracking-tighter">{{ __('Immediately whitelist item for this group') }}</span>
                                    </div>
                                </label>
                            @endforeach
                        </div>
                    </div>
                </div>

                {{-- SUBMIT ACTIONS --}}
                <div
                    class="flex items-center justify-end gap-4 p-6 bg-white rounded-3xl border border-gray-100 shadow-sm">
                    <a href="{{ route('items.index') }}"
                        class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">{{ __('Cancel') }}</a>
                    <x-primary-button
                        class="bg-blue-600 hover:bg-blue-700 px-10 py-4 rounded-2xl text-[10px] font-black uppercase shadow-lg shadow-blue-100">
                        {{ __('Create Product & Units') }}
                    </x-primary-button>
                </div>
            </form>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/categories/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Product Categories') }}
            </h2>
            {{-- ARCHITECTURE FIX: Matches items index button style [User Request] --}}
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">
            @can('create_items')
                <a href="{{ route('categories.create') }}" class="bg-blue-600 hover:bg-blue-700 text-white px-6 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-lg shadow-blue-100">
                    {{ __('+ New Category') }}
                </a>
            @endcan
            {{-- SEARCH TOOLBAR --}}
            <div class="bg-white p-6 rounded-[2rem] border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('categories.index') }}" class="flex gap-4">
                    <div class="flex-1 relative">
                        <x-text-input name="search" value="{{ request('search') }}" 
                                      placeholder="{{ __('Search category names...') }}" 
                                      class="w-full pl-10 pr-4 py-3 rounded-2xl border-gray-100 focus:ring-blue-500" />
                        <svg class="w-5 h-5 text-gray-300 absolute left-3 top-3.5" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" />
                        </svg>
                    </div>
                    <button type="submit" class="bg-gray-900 hover:bg-black text-white px-8 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-md">
                        {{ __('Filter') }}
                    </button>
                </form>
            </div>

            <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Category Name') }}</th>
                            <th class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Operational Status') }}</th>
                            <th class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Linked Items') }}</th>
                            <th class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">{{ __('Action') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50 bg-white">
                        {{-- ARCHITECTURE STANDARD: Maxtop Empty State Protocol --}}
                        @forelse ($categories as $category)
                            <tr class="hover:bg-gray-50/50 transition-colors">
                                <td class="px-8 py-5">
                                    <span class="text-sm font-black text-gray-700 uppercase tracking-tight">{{ $category->name }}</span>
                                </td>
                                <td class="px-6 py-5 text-center">
                                    <span class="px-3 py-1 rounded-full text-[9px] font-black uppercase border shadow-sm
                                        {{ $category->status === 'active' ? 'bg-green-50 text-green-700 border-green-200' : 'bg-red-50 text-red-700 border-red-200' }}">
                                        {{ $category->status }}
                                    </span>
                                </td>
                                <td class="px-6 py-5 text-center font-mono font-black text-xs text-gray-400">
                                    {{ $category->items_count }}
                                </td>
                                <td class="px-8 py-5 text-right">
                                    @can('edit_items')
                                        <a href="{{ route('categories.edit', $category) }}" 
                                           class="p-2 bg-white border border-gray-200 rounded-xl text-gray-400 hover:text-blue-600 transition shadow-sm inline-block">
                                            <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5">
                                                <path d="M15.232 5.232l3.536 3.536m-2.036-5.036a2.5 2.5 0 113.536 3.536L6.5 21.036H3v-3.572L16.732 3.732z" />
                                            </svg>
                                        </a>
                                    @endcan
                                </td>
                            </tr>
                        @empty
                            <tr>
                                <td colspan="100" class="px-8 py-20 text-center bg-white">
                                    <div class="flex flex-col items-center justify-center gap-4">
                                        <div class="w-16 h-16 bg-gray-50 rounded-[2rem] flex items-center justify-center border border-gray-100 shadow-inner">
                                            <svg class="w-6 h-6 text-gray-300" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2">
                                                <path stroke-linecap="round" stroke-linejoin="round" d="M20 13V6a2 2 0 00-2-2H6a2 2 0 00-2 2v7m16 0v5a2 2 0 01-2 2H6a2 2 0 01-2-2v-5m16 0h-2.586a1 1 0 00-.707.293l-2.414 2.414a1 1 0 01-.707.293h-3.172a1 1 0 01-.707-.293l-2.414-2.414A1 1 0 006.586 13H4" />
                                            </svg>
                                        </div>
                                        <div class="flex flex-col items-center">
                                            <span class="text-[11px] font-black uppercase text-gray-400 tracking-[0.2em]">{{ __('No Categories Found') }}</span>
                                            <p class="mt-1 text-[9px] font-bold text-gray-300 uppercase italic">{{ __('Try adjusting your search criteria or create a new category.') }}</p>
                                        </div>
                                    </div>
                                </td>
                            </tr>
                        @endforelse
                    </tbody>
                </table>
            </div>
            <div class="mt-6">{{ $categories->links() }}</div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/categories/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Edit Category') }}: <span class="text-blue-600">{{ $category->name }}</span>
            </h2>
            <a href="{{ route('categories.index') }}" class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                &larr; {{ __('Back to Registry') }}
            </a>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-3xl mx-auto sm:px-6 lg:px-8 space-y-8">
            
            <form method="POST" action="{{ route('categories.update', $category) }}" class="space-y-8">
                @csrf
                @method('PUT')

                <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100 p-10">
                    <div class="text-[10px] font-black uppercase text-gray-400 mb-8 tracking-widest flex items-center gap-2">
                        <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5"><path d="M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z" /></svg>
                        {{ __('Category Identity & Visibility') }}
                    </div>

                    <div class="space-y-8">
                        {{-- CATEGORY NAME --}}
                        <div>
                            <x-input-label for="name" :value="__('Category Identity (Display Name)')" class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                            <x-text-input id="name" name="name" type="text" class="mt-1 block w-full font-bold uppercase" :value="old('name', $category->name)" required />
                            <x-input-error :messages="$errors->get('name')" class="mt-2" />
                        </div>

                        {{-- OPERATIONAL STATUS --}}
                        <div>
                            <x-input-label for="status" :value="__('Operational Status')" class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                            <select name="status" id="status" class="w-full border-gray-300 rounded-xl shadow-sm focus:ring-blue-500 text-sm font-black uppercase">
                                <option value="active" @selected(old('status', $category->status) === 'active')>{{ __('Active (Visible in Catalogs)') }}</option>
                                <option value="deactive" @selected(old('status', $category->status) === 'deactive')>{{ __('Inactive (Hidden/Hold)') }}</option>
                            </select>
                            <x-input-error :messages="$errors->get('status')" class="mt-2" />
                        </div>
                    </div>
                </div>

                <div class="flex items-center justify-between">
                    {{-- ARCHITECTURE CHECK: Only show Hard Delete if no transaction records exist [User Request] --}}
                    @if($canBeDeleted)
                        <button type="button" 
                                onclick="if(confirm('{{ __('WARNING: This will permanently purge this category. This action is irreversible. Proceed?') }}')) document.getElementById('delete-category-form').submit();"
                                class="text-[10px] font-black uppercase text-red-400 hover:text-red-600 transition tracking-tighter">
                            {{ __('Hard Delete') }}
                        </button>
                    @else
                        <span class="text-[9px] font-black uppercase text-gray-300 italic flex items-center gap-2">
                            <svg class="w-3 h-3" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="3"><path d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" /></svg>
                            {{ __('Deletion Locked: Transaction Records Exist') }} [9.c.1]
                        </span>
                    @endif

                    <div class="flex items-center gap-4">
                        <a href="{{ route('categories.index') }}" class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                            {{ __('Cancel') }}
                        </a>
                        <x-primary-button class="bg-gray-900 hover:bg-black py-4 px-12 rounded-2xl shadow-lg transition-all uppercase text-[10px] font-black">
                            {{ __('Save Changes') }}
                        </x-primary-button>
                    </div>
                </div>
            </form>

            {{-- HIDDEN DELETE FORM --}}
            @if($canBeDeleted)
                <form id="delete-category-form" action="{{ route('categories.destroy', $category) }}" method="POST" class="hidden">
                    @csrf
                    @method('DELETE')
                </form>
            @endif
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/admin/categories/create.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Initialize New Category') }}
            </h2>
            <a href="{{ route('categories.index') }}" class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                &larr; {{ __('Back to Registry') }}
            </a>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-3xl mx-auto sm:px-6 lg:px-8">
            <form method="POST" action="{{ route('categories.store') }}" class="space-y-8">
                @csrf

                <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100 p-10">
                    <div class="text-[10px] font-black uppercase text-gray-400 mb-8 tracking-widest flex items-center gap-2">
                        <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2.5"><path d="M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10" /></svg>
                        {{ __('Category Definition') }}
                    </div>

                    <div class="space-y-8">
                        <div>
                            <x-input-label for="name" :value="__('Category Identity (Display Name)')" class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                            <x-text-input id="name" name="name" type="text" class="mt-1 block w-full font-bold uppercase" :value="old('name')" required autofocus />
                            <x-input-error :messages="$errors->get('name')" class="mt-2" />
                        </div>

                        <div>
                            <x-input-label for="status" :value="__('Initial Operational Status')" class="text-[10px] font-black uppercase text-gray-400 mb-2" />
                            <select name="status" id="status" class="w-full border-gray-300 rounded-xl shadow-sm focus:ring-blue-500 text-sm font-black uppercase">
                                <option value="active" @selected(old('status') === 'active')>{{ __('Active (Immediately Available for Catalogs)') }}</option>
                                <option value="deactive" @selected(old('status') === 'deactive')>{{ __('Inactive (System Hold)') }}</option>
                            </select>
                            <x-input-error :messages="$errors->get('status')" class="mt-2" />
                        </div>
                    </div>
                </div>

                <div class="flex items-center justify-end gap-4">
                    {{-- CANCEL: Redirects to index [User Request] --}}
                    <a href="{{ route('categories.index') }}" class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                        {{ __('Cancel') }}
                    </a>
                    {{-- CREATE: Redirects to index with success message [User Request] --}}
                    <x-primary-button class="bg-blue-600 hover:bg-blue-700 py-4 px-12 rounded-2xl shadow-lg shadow-blue-100 transition-all uppercase text-[10px] font-black">
                        {{ __('Create Category') }}
                    </x-primary-button>
                </div>
            </form>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/dropdown-link.blade.php ---
<a {{ $attributes->merge(['class' => 'block w-full px-4 py-2 text-start text-sm leading-5 text-gray-700 hover:bg-gray-100 focus:outline-none focus:bg-gray-100 transition duration-150 ease-in-out']) }}>{{ $slot }}</a>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/primary-button.blade.php ---
<button {{ $attributes->merge(['type' => 'submit', 'class' => 'inline-flex items-center px-4 py-2 bg-gray-800 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest hover:bg-gray-700 focus:bg-gray-700 active:bg-gray-900 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2 transition ease-in-out duration-150']) }}>
    {{ $slot }}
</button>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/secondary-button.blade.php ---
<button {{ $attributes->merge(['type' => 'button', 'class' => 'inline-flex items-center px-4 py-2 bg-white border border-gray-300 rounded-md font-semibold text-xs text-gray-700 uppercase tracking-widest shadow-sm hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2 disabled:opacity-25 transition ease-in-out duration-150']) }}>
    {{ $slot }}
</button>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/text-input.blade.php ---
@props(['disabled' => false])

<input @disabled($disabled) {{ $attributes->merge(['class' => 'border-gray-300 focus:border-indigo-500 focus:ring-indigo-500 rounded-md shadow-sm']) }}>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/application-logo.blade.php ---
<svg viewBox="0 0 316 316" xmlns="http://www.w3.org/2000/svg" {{ $attributes }}>
    <path d="M305.8 81.125C305.77 80.995 305.69 80.885 305.65 80.755C305.56 80.525 305.49 80.285 305.37 80.075C305.29 79.935 305.17 79.815 305.07 79.685C304.94 79.515 304.83 79.325 304.68 79.175C304.55 79.045 304.39 78.955 304.25 78.845C304.09 78.715 303.95 78.575 303.77 78.475L251.32 48.275C249.97 47.495 248.31 47.495 246.96 48.275L194.51 78.475C194.33 78.575 194.19 78.725 194.03 78.845C193.89 78.955 193.73 79.045 193.6 79.175C193.45 79.325 193.34 79.515 193.21 79.685C193.11 79.815 192.99 79.935 192.91 80.075C192.79 80.285 192.71 80.525 192.63 80.755C192.58 80.875 192.51 80.995 192.48 81.125C192.38 81.495 192.33 81.875 192.33 82.265V139.625L148.62 164.795V52.575C148.62 52.185 148.57 51.805 148.47 51.435C148.44 51.305 148.36 51.195 148.32 51.065C148.23 50.835 148.16 50.595 148.04 50.385C147.96 50.245 147.84 50.125 147.74 49.995C147.61 49.825 147.5 49.635 147.35 49.485C147.22 49.355 147.06 49.265 146.92 49.155C146.76 49.025 146.62 48.885 146.44 48.785L93.99 18.585C92.64 17.805 90.98 17.805 89.63 18.585L37.18 48.785C37 48.885 36.86 49.035 36.7 49.155C36.56 49.265 36.4 49.355 36.27 49.485C36.12 49.635 36.01 49.825 35.88 49.995C35.78 50.125 35.66 50.245 35.58 50.385C35.46 50.595 35.38 50.835 35.3 51.065C35.25 51.185 35.18 51.305 35.15 51.435C35.05 51.805 35 52.185 35 52.575V232.235C35 233.795 35.84 235.245 37.19 236.025L142.1 296.425C142.33 296.555 142.58 296.635 142.82 296.725C142.93 296.765 143.04 296.835 143.16 296.865C143.53 296.965 143.9 297.015 144.28 297.015C144.66 297.015 145.03 296.965 145.4 296.865C145.5 296.835 145.59 296.775 145.69 296.745C145.95 296.655 146.21 296.565 146.45 296.435L251.36 236.035C252.72 235.255 253.55 233.815 253.55 232.245V174.885L303.81 145.945C305.17 145.165 306 143.725 306 142.155V82.265C305.95 81.875 305.89 81.495 305.8 81.125ZM144.2 227.205L100.57 202.515L146.39 176.135L196.66 147.195L240.33 172.335L208.29 190.625L144.2 227.205ZM244.75 114.995V164.795L226.39 154.225L201.03 139.625V89.825L219.39 100.395L244.75 114.995ZM249.12 57.105L292.81 82.265L249.12 107.425L205.43 82.265L249.12 57.105ZM114.49 184.425L96.13 194.995V85.305L121.49 70.705L139.85 60.135V169.815L114.49 184.425ZM91.76 27.425L135.45 52.585L91.76 77.745L48.07 52.585L91.76 27.425ZM43.67 60.135L62.03 70.705L87.39 85.305V202.545V202.555V202.565C87.39 202.735 87.44 202.895 87.46 203.055C87.49 203.265 87.49 203.485 87.55 203.695V203.705C87.6 203.875 87.69 204.035 87.76 204.195C87.84 204.375 87.89 204.575 87.99 204.745C87.99 204.745 87.99 204.755 88 204.755C88.09 204.905 88.22 205.035 88.33 205.175C88.45 205.335 88.55 205.495 88.69 205.635L88.7 205.645C88.82 205.765 88.98 205.855 89.12 205.965C89.28 206.085 89.42 206.225 89.59 206.325C89.6 206.325 89.6 206.325 89.61 206.335C89.62 206.335 89.62 206.345 89.63 206.345L139.87 234.775V285.065L43.67 229.705V60.135ZM244.75 229.705L148.58 285.075V234.775L219.8 194.115L244.75 179.875V229.705ZM297.2 139.625L253.49 164.795V114.995L278.85 100.395L297.21 89.825V139.625H297.2Z"/>
</svg>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/filter-toolbar.blade.php ---
@props(['placeholder' => __('Search...'), 'showDates' => false])

<div x-data="{
    submit() { this.$refs.filterForm.submit() }
}" class="bg-white p-4 rounded-2xl border border-gray-100 shadow-sm mb-8">
    <form x-ref="filterForm" action="{{ url()->current() }}" method="GET"
        class="flex flex-col md:flex-row gap-4 items-center">

        {{-- Smart Search Input --}}
        <div class="relative w-full md:grow">
            <div class="absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none">
                <svg class="h-4 w-4 text-gray-400" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                    <path stroke-linecap="round" stroke-linejoin="round" stroke-width="3"
                        d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" />
                </svg>
            </div>
            <input type="text" name="search" value="{{ request('search') }}" @keyup.enter="submit()"
                class="block w-full pl-10 pr-3 py-2 border-gray-200 rounded-xl text-sm focus:ring-maxtop focus:border-maxtop transition-all placeholder-gray-400"
                placeholder="{{ $placeholder }}">
        </div>

        {{-- Dynamic "Smart" Slot for Dropdowns (Role, Status, Category) --}}
        @if (!$slot->isEmpty())
            <div class="flex gap-2 w-full md:w-auto" @change="submit()">
                {{ $slot }}
            </div>
        @endif

        {{-- Contextual Date Ranges (Hidden by default) --}}
        @if ($showDates)
            <div class="flex items-center gap-2">
                <input type="date" name="start_date" value="{{ request('start_date') }}" @change="submit()"
                    class="text-xs border-gray-200 rounded-lg focus:ring-maxtop focus:border-maxtop">
                <span class="text-gray-300">-</span>
                <input type="date" name="end_date" value="{{ request('end_date') }}" @change="submit()"
                    class="text-xs border-gray-200 rounded-lg focus:ring-maxtop focus:border-maxtop">
            </div>
        @endif

        {{-- Reset Button --}}
        @if (request()->hasAny(['search', 'role', 'status', 'category', 'start_date', 'end_date']))
            <a href="{{ url()->current() }}"
                class="text-[10px] font-black uppercase text-gray-400 hover:text-red-600 transition-colors">
                {{ __('Clear All') }}
            </a>
        @endif
    </form>
</div>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/nav-link.blade.php ---
@props(['active'])

@php
    $classes =
        $active ?? false
            ? 'block w-full text-left pl-4 pr-6 py-2 border-l-4 border-indigo-400 text-base font-medium text-indigo-700 bg-indigo-50 focus:outline-none focus:text-indigo-800 focus:bg-indigo-100 focus:border-indigo-700 transition duration-150 ease-in-out'
            : 'block w-full text-left pl-4 pr-6 py-2 border-l-4 border-transparent text-base font-medium text-gray-600 hover:text-gray-800 hover:bg-gray-50 hover:border-gray-300 focus:outline-none focus:text-gray-800 focus:bg-gray-50 focus:border-gray-300 transition duration-150 ease-in-out';
@endphp

<a {{ $attributes->merge(['class' => $classes]) }}>
    {{ $slot }}
</a>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/input-label.blade.php ---
@props(['value'])

<label {{ $attributes->merge(['class' => 'block font-medium text-sm text-gray-700']) }}>
    {{ $value ?? $slot }}
</label>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/input-error.blade.php ---
@props(['messages'])

@if ($messages)
    <ul {{ $attributes->merge(['class' => 'text-sm text-red-600 space-y-1']) }}>
        @foreach ((array) $messages as $message)
            <li>{{ $message }}</li>
        @endforeach
    </ul>
@endif

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/dropdown.blade.php ---
@props(['align' => 'right', 'width' => '48', 'contentClasses' => 'py-1 bg-white'])

@php
$alignmentClasses = match ($align) {
    'left' => 'ltr:origin-top-left rtl:origin-top-right start-0',
    'top' => 'origin-top',
    default => 'ltr:origin-top-right rtl:origin-top-left end-0',
};

$width = match ($width) {
    '48' => 'w-48',
    default => $width,
};
@endphp

<div class="relative" x-data="{ open: false }" @click.outside="open = false" @close.stop="open = false">
    <div @click="open = ! open">
        {{ $trigger }}
    </div>

    <div x-show="open"
            x-transition:enter="transition ease-out duration-200"
            x-transition:enter-start="opacity-0 scale-95"
            x-transition:enter-end="opacity-100 scale-100"
            x-transition:leave="transition ease-in duration-75"
            x-transition:leave-start="opacity-100 scale-100"
            x-transition:leave-end="opacity-0 scale-95"
            class="absolute z-50 mt-2 {{ $width }} rounded-md shadow-lg {{ $alignmentClasses }}"
            style="display: none;"
            @click="open = false">
        <div class="rounded-md ring-1 ring-black ring-opacity-5 {{ $contentClasses }}">
            {{ $content }}
        </div>
    </div>
</div>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/responsive-nav-link.blade.php ---
@props(['active'])

@php
$classes = ($active ?? false)
            ? 'block w-full ps-3 pe-4 py-2 border-l-4 border-indigo-400 text-start text-base font-medium text-indigo-700 bg-indigo-50 focus:outline-none focus:text-indigo-800 focus:bg-indigo-100 focus:border-indigo-700 transition duration-150 ease-in-out'
            : 'block w-full ps-3 pe-4 py-2 border-l-4 border-transparent text-start text-base font-medium text-gray-600 hover:text-gray-800 hover:bg-gray-50 hover:border-gray-300 focus:outline-none focus:text-gray-800 focus:bg-gray-50 focus:border-gray-300 transition duration-150 ease-in-out';
@endphp

<a {{ $attributes->merge(['class' => $classes]) }}>
    {{ $slot }}
</a>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/danger-button.blade.php ---
<button {{ $attributes->merge(['type' => 'submit', 'class' => 'inline-flex items-center px-4 py-2 bg-red-600 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest hover:bg-red-500 active:bg-red-700 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 transition ease-in-out duration-150']) }}>
    {{ $slot }}
</button>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/auth-session-status.blade.php ---
@props(['status'])

@if ($status)
    <div {{ $attributes->merge(['class' => 'font-medium text-sm text-green-600']) }}>
        {{ $status }}
    </div>
@endif

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/components/modal.blade.php ---
@props([
    'name',
    'show' => false,
    'maxWidth' => '2xl'
])

@php
$maxWidth = [
    'sm' => 'sm:max-w-sm',
    'md' => 'sm:max-w-md',
    'lg' => 'sm:max-w-lg',
    'xl' => 'sm:max-w-xl',
    '2xl' => 'sm:max-w-2xl',
][$maxWidth];
@endphp

<div
    x-data="{
        show: @js($show),
        focusables() {
            // All focusable element types...
            let selector = 'a, button, input:not([type=\'hidden\']), textarea, select, details, [tabindex]:not([tabindex=\'-1\'])'
            return [...$el.querySelectorAll(selector)]
                // All non-disabled elements...
                .filter(el => ! el.hasAttribute('disabled'))
        },
        firstFocusable() { return this.focusables()[0] },
        lastFocusable() { return this.focusables().slice(-1)[0] },
        nextFocusable() { return this.focusables()[this.nextFocusableIndex()] || this.firstFocusable() },
        prevFocusable() { return this.focusables()[this.prevFocusableIndex()] || this.lastFocusable() },
        nextFocusableIndex() { return (this.focusables().indexOf(document.activeElement) + 1) % (this.focusables().length + 1) },
        prevFocusableIndex() { return Math.max(0, this.focusables().indexOf(document.activeElement)) -1 },
    }"
    x-init="$watch('show', value => {
        if (value) {
            document.body.classList.add('overflow-y-hidden');
            {{ $attributes->has('focusable') ? 'setTimeout(() => firstFocusable().focus(), 100)' : '' }}
        } else {
            document.body.classList.remove('overflow-y-hidden');
        }
    })"
    x-on:open-modal.window="$event.detail == '{{ $name }}' ? show = true : null"
    x-on:close-modal.window="$event.detail == '{{ $name }}' ? show = false : null"
    x-on:close.stop="show = false"
    x-on:keydown.escape.window="show = false"
    x-on:keydown.tab.prevent="$event.shiftKey || nextFocusable().focus()"
    x-on:keydown.shift.tab.prevent="prevFocusable().focus()"
    x-show="show"
    class="fixed inset-0 overflow-y-auto px-4 py-6 sm:px-0 z-50"
    style="display: {{ $show ? 'block' : 'none' }};"
>
    <div
        x-show="show"
        class="fixed inset-0 transform transition-all"
        x-on:click="show = false"
        x-transition:enter="ease-out duration-300"
        x-transition:enter-start="opacity-0"
        x-transition:enter-end="opacity-100"
        x-transition:leave="ease-in duration-200"
        x-transition:leave-start="opacity-100"
        x-transition:leave-end="opacity-0"
    >
        <div class="absolute inset-0 bg-gray-500 opacity-75"></div>
    </div>

    <div
        x-show="show"
        class="mb-6 bg-white rounded-lg overflow-hidden shadow-xl transform transition-all sm:w-full {{ $maxWidth }} sm:mx-auto"
        x-transition:enter="ease-out duration-300"
        x-transition:enter-start="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
        x-transition:enter-end="opacity-100 translate-y-0 sm:scale-100"
        x-transition:leave="ease-in duration-200"
        x-transition:leave-start="opacity-100 translate-y-0 sm:scale-100"
        x-transition:leave-end="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
    >
        {{ $slot }}
    </div>
</div>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/dashboard.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('Dashboard') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg">
                <div class="p-6 text-gray-900">
                    {{ __("You're logged in!") }}
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/profile/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('My Business Profile') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-4xl mx-auto sm:px-6 lg:px-8 space-y-8">

            {{-- 1. IDENTITY CARD: READ-ONLY [Backbone 3.b] --}}
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-[2.5rem] border border-gray-100">
                <div class="p-10">
                    <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-6 mb-12">
                        <div class="flex items-center gap-5">
                            <div
                                class="w-16 h-16 bg-blue-600 rounded-[1.5rem] flex items-center justify-center text-white text-xl font-black shadow-lg shadow-blue-100">
                                {{ strtoupper(substr($user->name, 0, 1)) }}
                            </div>
                            <div>
                                <h3 class="text-xl font-black text-gray-900">{{ $user->name }}</h3>
                                <p class="text-xs font-bold text-blue-600 uppercase tracking-widest">
                                    {{ $user->roles->first()->name ?? 'Customer' }}</p>
                            </div>
                        </div>

                        {{-- COMMUNICATION PROTOCOL: Direct link to assigned CS Rep [12.a] --}}
                        <a href="mailto:{{ $user->csRepresentative->email ?? 'cs@maxtop.com' }}?subject=Profile Update Request: {{ $user->login_id }}"
                            class="bg-gray-900 hover:bg-black text-white px-6 py-3 rounded-2xl text-[10px] font-black uppercase transition-all shadow-xl shadow-gray-200 flex items-center gap-2">
                            <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                                stroke-width="2.5">
                                <path
                                    d="M11 5H6a2 2 0 00-2 2v11a2 2 0 002 2h11a2 2 0 002-2v-5m-1.414-9.414a2 2 0 112.828 2.828L11.828 15H9v-2.828l8.586-8.586z" />
                            </svg>
                            {{ __('Request Profile Modification') }}
                        </a>
                    </div>

                    <div class="grid grid-cols-1 md:grid-cols-2 gap-x-12 gap-y-8">
                        {{-- Security Data --}}
                        <div class="space-y-6">
                            <div>
                                <label
                                    class="text-[10px] font-black text-gray-400 uppercase tracking-widest block mb-2">{{ __('Login Identity (Locked)') }}</label>
                                <div
                                    class="bg-gray-50 border border-gray-100 px-4 py-3 rounded-xl font-mono text-sm font-bold text-gray-500 uppercase tracking-tighter">
                                    {{ $user->login_id }}
                                </div>
                            </div>
                            <div>
                                <label
                                    class="text-[10px] font-black text-gray-400 uppercase tracking-widest block mb-2">{{ __('Registered Email') }}</label>
                                <div class="text-sm font-bold text-gray-700">{{ $user->email }}</div>
                            </div>
                        </div>

                        {{-- Business Data --}}
                        <div class="space-y-6">
                            <div>
                                <label
                                    class="text-[10px] font-black text-gray-400 uppercase tracking-widest block mb-2">{{ __('Assigned Business Entity') }}</label>
                                <div class="flex flex-col">
                                    <span
                                        class="text-sm font-black text-gray-900">{{ $user->company->company_name ?? __('N/A') }}</span>
                                    <span
                                        class="text-[10px] font-mono font-black text-blue-500 uppercase tracking-tighter">
                                        {{ $user->company->company_code ?? ($user->company->branch_code ?? __('NO_CODE')) }}
                                    </span>
                                </div>
                            </div>
                            <div>
                                <label
                                    class="text-[10px] font-black text-gray-400 uppercase tracking-widest block mb-2">{{ __('Responsible CS Representative') }}</label>
                                <div class="flex items-center gap-2">
                                    <div class="w-2 h-2 bg-green-500 rounded-full animate-pulse"></div>
                                    <span
                                        class="text-sm font-bold text-gray-700">{{ $user->csRepresentative->name ?? __('Maxtop General Support') }}</span>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="bg-gray-50 px-10 py-6 border-t border-gray-100 flex items-center gap-3">
                    <svg class="w-5 h-5 text-gray-400" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                        stroke-width="2">
                        <path
                            d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                    </svg>
                    <p class="text-[9px] font-black text-gray-400 uppercase tracking-widest leading-relaxed">
                        {{ __('To maintain B2B account integrity, profile modifications must be verified and performed by your assigned representative.') }}
                    </p>
                </div>
            </div>

            {{-- 2. PASSWORD MANAGEMENT: EDITABLE [v1.4 Security Policy] --}}
            <div class="p-8 bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100">
                <div class="max-w-xl">
                    @include('profile.partials.update-password-form')
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/profile/partials/delete-user-form.blade.php ---
<section class="space-y-6">
    <header>
        <h2 class="text-lg font-medium text-gray-900">
            {{ __('Delete Account') }}
        </h2>

        <p class="mt-1 text-sm text-gray-600">
            {{ __('Once your account is deleted, all of its resources and data will be permanently deleted. Before deleting your account, please download any data or information that you wish to retain.') }}
        </p>
    </header>

    <x-danger-button
        x-data=""
        x-on:click.prevent="$dispatch('open-modal', 'confirm-user-deletion')"
    >{{ __('Delete Account') }}</x-danger-button>

    <x-modal name="confirm-user-deletion" :show="$errors->userDeletion->isNotEmpty()" focusable>
        <form method="post" action="{{ route('profile.destroy') }}" class="p-6">
            @csrf
            @method('delete')

            <h2 class="text-lg font-medium text-gray-900">
                {{ __('Are you sure you want to delete your account?') }}
            </h2>

            <p class="mt-1 text-sm text-gray-600">
                {{ __('Once your account is deleted, all of its resources and data will be permanently deleted. Please enter your password to confirm you would like to permanently delete your account.') }}
            </p>

            <div class="mt-6">
                <x-input-label for="password" value="{{ __('Password') }}" class="sr-only" />

                <x-text-input
                    id="password"
                    name="password"
                    type="password"
                    class="mt-1 block w-3/4"
                    placeholder="{{ __('Password') }}"
                />

                <x-input-error :messages="$errors->userDeletion->get('password')" class="mt-2" />
            </div>

            <div class="mt-6 flex justify-end">
                <x-secondary-button x-on:click="$dispatch('close')">
                    {{ __('Cancel') }}
                </x-secondary-button>

                <x-danger-button class="ms-3">
                    {{ __('Delete Account') }}
                </x-danger-button>
            </div>
        </form>
    </x-modal>
</section>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/profile/partials/update-password-form.blade.php ---
<section>
    <header>
        <h2 class="text-lg font-medium text-gray-900">
            {{ __('Update Password') }}
        </h2>

        <p class="mt-1 text-sm text-gray-600">
            {{ __('Ensure your account is using a long, random password to stay secure.') }}
        </p>
    </header>

    <form method="post" action="{{ route('password.update') }}" class="mt-6 space-y-6">
        @csrf
        @method('put')

        <div>
            <x-input-label for="update_password_current_password" :value="__('Current Password')" />
            <x-text-input id="update_password_current_password" name="current_password" type="password" class="mt-1 block w-full" autocomplete="current-password" />
            <x-input-error :messages="$errors->updatePassword->get('current_password')" class="mt-2" />
        </div>

        <div>
            <x-input-label for="update_password_password" :value="__('New Password')" />
            <x-text-input id="update_password_password" name="password" type="password" class="mt-1 block w-full" autocomplete="new-password" />
            <x-input-error :messages="$errors->updatePassword->get('password')" class="mt-2" />
        </div>

        <div>
            <x-input-label for="update_password_password_confirmation" :value="__('Confirm Password')" />
            <x-text-input id="update_password_password_confirmation" name="password_confirmation" type="password" class="mt-1 block w-full" autocomplete="new-password" />
            <x-input-error :messages="$errors->updatePassword->get('password_confirmation')" class="mt-2" />
        </div>

        <div class="flex items-center gap-4">
            <x-primary-button>{{ __('Save') }}</x-primary-button>

            @if (session('status') === 'password-updated')
                <p
                    x-data="{ show: true }"
                    x-show="show"
                    x-transition
                    x-init="setTimeout(() => show = false, 2000)"
                    class="text-sm text-gray-600"
                >{{ __('Saved.') }}</p>
            @endif
        </div>
    </form>
</section>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/profile/partials/update-profile-information-form.blade.php ---
<section>
    <header>
        <h2 class="text-lg font-medium text-gray-900">
            {{ __('Profile Information') }}
        </h2>

        <p class="mt-1 text-sm text-gray-600">
            {{ __("Update your account's profile information and email address.") }}
        </p>
    </header>

    <form id="send-verification" method="post" action="{{ route('verification.send') }}">
        @csrf
    </form>

    <form method="post" action="{{ route('profile.update') }}" class="mt-6 space-y-6">
        @csrf
        @method('patch')

        <div>
            <x-input-label for="name" :value="__('Name')" />
            <x-text-input id="name" name="name" type="text" class="mt-1 block w-full" :value="old('name', $user->name)" required autofocus autocomplete="name" />
            <x-input-error class="mt-2" :messages="$errors->get('name')" />
        </div>

        <div>
            <x-input-label for="email" :value="__('Email')" />
            <x-text-input id="email" name="email" type="email" class="mt-1 block w-full" :value="old('email', $user->email)" required autocomplete="username" />
            <x-input-error class="mt-2" :messages="$errors->get('email')" />

            @if ($user instanceof \Illuminate\Contracts\Auth\MustVerifyEmail && ! $user->hasVerifiedEmail())
                <div>
                    <p class="text-sm mt-2 text-gray-800">
                        {{ __('Your email address is unverified.') }}

                        <button form="send-verification" class="underline text-sm text-gray-600 hover:text-gray-900 rounded-md focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
                            {{ __('Click here to re-send the verification email.') }}
                        </button>
                    </p>

                    @if (session('status') === 'verification-link-sent')
                        <p class="mt-2 font-medium text-sm text-green-600">
                            {{ __('A new verification link has been sent to your email address.') }}
                        </p>
                    @endif
                </div>
            @endif
        </div>

        <div class="flex items-center gap-4">
            <x-primary-button>{{ __('Save') }}</x-primary-button>

            @if (session('status') === 'profile-updated')
                <p
                    x-data="{ show: true }"
                    x-show="show"
                    x-transition
                    x-init="setTimeout(() => show = false, 2000)"
                    class="text-sm text-gray-600"
                >{{ __('Saved.') }}</p>
            @endif
        </div>
    </form>
</section>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/layouts/navigation.blade.php ---
<nav x-data="{ open: false }" class="bg-white border-b border-gray-100">
    <!-- Primary Navigation Menu -->
    <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
        <div class="flex justify-between h-16">
            <div class="flex">
                <!-- Logo -->
                <div class="shrink-0 flex items-center">
                    <a href="{{ route('dashboard') }}">
                        <x-application-logo class="block h-9 w-auto fill-current text-gray-800" />
                    </a>
                </div>
            </div>

        </div>
    </div>

    <!-- Sidebar -->
    <div class="pt-4 pb-1 border-t border-gray-200">
        @role('customer')
            <x-nav-link :href="route('customer.products.index')" :active="request()->routeIs('customer.products.index')">
                {{ __('Order Products') }}
            </x-nav-link>

            <x-nav-link :href="route('customer.orders.index')" :active="request()->routeIs('customer.orders.index')">
                {{ __('My Order History') }}
            </x-nav-link>

            <x-nav-link :href="route('reservation.index')" :active="request()->routeIs('reservation.index')">
                {{ __('My Reservation Draft') }}
            </x-nav-link>
        @endrole
        @hasanyrole('admin|cs_leader|cs_staff')
            <div class="px-4 py-2 font-black text-xs uppercase text-gray-400 tracking-widest">{{ __('Office Operations') }}
            </div>

            @can('view_items')
                <x-nav-link :href="route('items.index')" :active="request()->routeIs('items.*')">
                    {{ __('Product Items') }}
                </x-nav-link>

                {{-- Fulfills Item Grouping Management Requirement --}}
                <x-nav-link :href="route('categories.index')" :active="request()->routeIs('categories.*')">
                    {{ __('Product Categories') }}
                </x-nav-link>
            @endcan

            @can('view_catalogs')
                <x-nav-link :href="route('catalogs.index')" :active="request()->routeIs('catalogs.*')">
                    {{ __('Catalog Folders') }}
                </x-nav-link>
            @endcan

            {{-- ARCHITECTURE FIX: Split "Business Entities" permission --}}
            @can('view_business_entities')
                <x-nav-link :href="route('companys.index')" :active="request()->routeIs('companys.*')">
                    {{ __('Business Entities') }}
                </x-nav-link>
            @endcan

            {{-- ARCHITECTURE FIX: Split "Login Credentials" permission --}}
            @can('view_login_credentials')
                <x-nav-link :href="route('users.index')" :active="request()->routeIs('users.index')">
                    {{ __('Login Credentials') }}
                </x-nav-link>
            @endcan

            @can('view_assigned_customers')
                <x-nav-link :href="route('users.assigned')" :active="request()->routeIs('users.assigned')">
                    {{ __('My Customers') }}
                </x-nav-link>
            @endcan

            <x-nav-link :href="route('dashboard')" :active="request()->routeIs('dashboard')">
                {{ __('Order Overview') }}
            </x-nav-link>
        @endhasanyrole

        @role('admin')
            <div class="pt-4 pb-1 border-t border-gray-100">
                <div class="px-4 text-[10px] font-black uppercase text-gray-400 tracking-widest mb-4">
                    {{ __('System Control') }}
                </div>

                <x-nav-link :href="route('admin.roles.manage.index')" :active="request()->routeIs('admin.roles.manage.*')">
                    {{ __('Role Registry') }}
                </x-nav-link>

                <x-nav-link :href="route('admin.roles.matrix')" :active="request()->routeIs('admin.roles.matrix')">
                    {{ __('Feature Settings') }}
                </x-nav-link>

                {{-- ARCHITECTURE FIX: Updated to match new 'admin.activity.index' name --}}
                <x-nav-link :href="route('admin.activity.index')" :active="request()->routeIs('admin.activity.*')">
                    {{ __('Activity Log') }}
                </x-nav-link>
            </div>
        @endrole
    </div>

    <!-- Responsive Settings Options -->
    <div class="pt-4 pb-1 border-t border-gray-200">
        {{-- Consolidated Identity & Profile Link: Fulfills standard UI/UX consolidation --}}
        <a href="{{ route('profile.edit') }}"
            class="block px-4 py-2 hover:bg-gray-100 transition duration-150 ease-in-out">
            <div class="text-sm font-medium text-gray-800">{{ Auth::user()->name }}</div>
            <div class="text-xs text-gray-500">{{ Auth::user()->email }}</div>
        </a>

        <div class="mt-3 space-y-1">
            <form method="POST" action="{{ route('logout') }}">
                @csrf
                <x-responsive-nav-link :href="route('logout')"
                    onclick="event.preventDefault();
                                    this.closest('form').submit();">
                    {{ __('Log Out') }}
                </x-responsive-nav-link>
            </form>
        </div>
    </div>
</nav>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/layouts/guest.blade.php ---
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <meta name="csrf-token" content="{{ csrf_token() }}">

        <title>{{ config('app.name', 'Laravel') }}</title>

        <!-- Fonts -->
        <link rel="preconnect" href="https://fonts.bunny.net">
        <link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />

        <!-- Scripts -->
        @vite(['resources/css/app.css', 'resources/js/app.js'])
    </head>
    <body class="font-sans text-gray-900 antialiased">
        <div class="min-h-screen flex flex-col sm:justify-center items-center pt-6 sm:pt-0 bg-gray-100">
            <div>
                <a href="/">
                    <x-application-logo class="w-20 h-20 fill-current text-gray-500" />
                </a>
            </div>

            <div class="w-full sm:max-w-md mt-6 px-6 py-4 bg-white shadow-md overflow-hidden sm:rounded-lg">
                {{ $slot }}
            </div>
        </div>
    </body>
</html>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/layouts/app.blade.php ---
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="csrf-token" content="{{ csrf_token() }}">

    <title>{{ config('app.name', 'Laravel') }}</title>

    <!-- Fonts -->
    <link rel="preconnect" href="https://fonts.bunny.net">
    <link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />

    <!-- Scripts -->
    @vite(['resources/css/app.css', 'resources/js/app.js'])
</head>

<body class="font-sans antialiased">
    <div class="min-h-screen bg-gray-100 flex" x-data="{ open: false }">

        <aside class="bg-white border-r border-gray-100 w-64 min-h-screen hidden md:block">
            @include('layouts.navigation')
        </aside>

        <div x-show="open" @click="open = false" class="fixed inset-0 z-40 bg-black opacity-50 md:hidden"
            style="display: none;"></div>

        <aside :class="{ 'translate-x-0': open, '-translate-x-full': !open }"
            class="fixed inset-y-0 left-0 z-50 w-64 bg-white border-r border-gray-100 transition-transform duration-300 ease-in-out md:hidden transform -translate-x-full">
            @include('layouts.navigation')
        </aside>

        <div class="flex-1 flex flex-col min-w-0 overflow-hidden">

            <header class="bg-white shadow flex justify-between items-center p-4 md:hidden">
                <button @click="open = ! open" class="text-gray-500 focus:outline-none">
                    <svg class="h-6 w-6" stroke="currentColor" fill="none" viewBox="0 0 24 24">
                        <path :class="{ 'hidden': open, 'inline-flex': !open }" class="inline-flex"
                            stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
                            d="M4 6h16M4 12h16M4 18h16" />
                        <path :class="{ 'hidden': !open, 'inline-flex': open }" class="hidden" stroke-linecap="round"
                            stroke-linejoin="round" stroke-width="2" d="M6 18L18 6M6 6l12 12" />
                    </svg>
                </button>
            </header>

            <main class="flex-1 overflow-y-auto p-6">
                {{ $slot }}
            </main>
        </div>
    </div>
</body>

</html>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/users/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Login Credentials') }}
            </h2>
        </div>
    </x-slot>

    <div class="py-12">
        @can('create_users')
            <a href="{{ route('users.create') }}"
                class="inline-flex items-center bg-blue-600 hover:bg-blue-700 text-white px-5 py-2.5 rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-blue-200">
                <svg class="w-4 h-4 mr-2" fill="none" viewBox="0 0 24 24" stroke="currentColor font-black">
                    <path stroke-linecap="round" stroke-linejoin="round" stroke-width="3" d="M12 4v16m8-8H4" />
                </svg>
                {{ __('Create New Login') }}
            </a>
        @endcan
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">

            {{-- Search & Filter Toolbar: Fulfills standard UI consistency --}}
            <div class="bg-white p-6 rounded-3xl border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('users.index') }}">
                    <x-filter-toolbar :placeholder="__('Search Name, Login ID or Email...')" :showDates="true">
                        {{-- Role Filter Slot --}}
                        <select name="role"
                            class="text-xs border-gray-200 rounded-xl font-bold uppercase text-gray-600 focus:ring-blue-500 focus:border-blue-500">
                            <option value="">{{ __('All Roles') }}</option>
                            @foreach ($roles as $roleName)
                                <option value="{{ $roleName }}"
                                    {{ request('role') == $roleName ? 'selected' : '' }}>
                                    {{ ucfirst(str_replace('_', ' ', $roleName)) }}
                                </option>
                            @endforeach
                        </select>

                        {{-- Status Filter Slot --}}
                        <select name="status"
                            class="text-xs border-gray-200 rounded-xl font-bold uppercase text-gray-600 focus:ring-blue-500 focus:border-blue-500">
                            <option value="">{{ __('All Status') }}</option>
                            @foreach ($status as $statusName)
                                <option value="{{ $statusName }}"
                                    {{ request('status') == $statusName ? 'selected' : '' }}>
                                    {{ ucfirst($statusName) }}
                                </option>
                            @endforeach
                        </select>
                    </x-filter-toolbar>
                </form>
            </div>

            {{-- Users Master Table --}}
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100">
                <div class="overflow-x-auto">
                    <table class="min-w-full divide-y divide-gray-100">
                        <thead class="bg-gray-50">
                            <tr>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('User / Login ID') }}</th>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Assigned Company') }}</th>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Role') }}</th>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Status') }}</th>
                                <th
                                    class="px-6 py-4 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Actions') }}</th>
                            </tr>
                        </thead>
                        <tbody class="bg-white divide-y divide-gray-50">
                            @forelse ($users as $user)
                                <tr class="hover:bg-gray-50/50 transition-colors">
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        <div class="flex flex-col">
                                            <span class="text-sm font-bold text-gray-900">{{ $user->name }}</span>
                                            <span
                                                class="text-[10px] font-black text-blue-500 uppercase tracking-tighter">{{ $user->login_id }}</span>
                                            <span class="text-[10px] text-gray-400">{{ $user->email }}</span>
                                        </div>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        @if ($user->company)
                                            <div class="flex flex-col">
                                                <span
                                                    class="text-xs font-bold text-gray-700">{{ $user->company->company_name }}</span>
                                                <span class="text-[10px] font-mono text-gray-400 uppercase">
                                                    {{ $user->company->company_code ?? $user->company->branch_code }}
                                                </span>
                                            </div>
                                        @else
                                            <span
                                                class="px-2 py-1 rounded-md bg-gray-100 text-gray-400 text-[9px] font-black uppercase italic">
                                                {{ __('Internal / Unassigned') }}
                                            </span>
                                        @endif
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        @foreach ($user->roles as $role)
                                            <span
                                                class="px-2 py-1 rounded-full bg-indigo-50 text-indigo-700 text-[9px] font-black uppercase border border-indigo-100">
                                                {{ str_replace('_', ' ', $role->name) }}
                                            </span>
                                        @endforeach
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        <span
                                            class="inline-flex items-center px-2.5 py-0.5 rounded-full text-[10px] font-black uppercase tracking-tight {{ $user->status === 'active' ? 'bg-green-100 text-green-700' : 'bg-red-100 text-red-700' }}">
                                            <span
                                                class="w-1.5 h-1.5 mr-1.5 rounded-full {{ $user->status === 'active' ? 'bg-green-500' : 'bg-red-500' }}"></span>
                                            {{ $user->status }}
                                        </span>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap text-right">
                                        <div class="flex justify-end gap-2">
                                            <a href="{{ route('users.edit', $user) }}"
                                                class="inline-flex items-center bg-white border border-gray-200 text-gray-700 px-3 py-1.5 rounded-xl text-[10px] font-black uppercase hover:bg-gray-50 transition shadow-sm">
                                                {{ __('Edit Profile') }}
                                            </a>
                                        </div>
                                    </td>
                                </tr>
                            @empty
                                <tr>
                                    <td colspan="5" class="px-6 py-12 text-center">
                                        <div class="flex flex-col items-center">
                                            <p class="text-gray-400 text-xs font-bold uppercase tracking-widest">
                                                {{ __('No user credentials found matching your filters.') }}</p>
                                        </div>
                                    </td>
                                </tr>
                            @endforelse
                        </tbody>
                    </table>
                </div>

                {{-- Pagination: Preserves search/filter state --}}
                @if ($users->hasPages())
                    <div class="p-6 bg-gray-50 border-t border-gray-100">
                        {{ $users->links() }}
                    </div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/users/assigned.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('My Assigned Customers') }}
            </h2>
            <a href="{{ route('users.create') }}"
                class="inline-flex items-center bg-blue-600 hover:bg-blue-700 text-white px-5 py-2.5 rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-blue-200">
                <svg class="w-4 h-4 mr-2" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="3">
                    <path stroke-linecap="round" stroke-linejoin="round" d="M12 4v16m8-8H4" />
                </svg>
                {{ __('Onboard New Login') }}
            </a>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-6">

            {{-- Search & Filter Toolbar: Fulfills UI consistency requirements --}}
            <div class="bg-white p-6 rounded-3xl border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('users.assigned') }}">
                    <x-filter-toolbar :placeholder="__('Search assigned names or login IDs...')" :showDates="false">
                        <select name="role"
                            class="text-xs border-gray-200 rounded-xl font-bold uppercase text-gray-600 focus:ring-blue-500 focus:border-blue-500">
                            <option value="">{{ __('All Roles') }}</option>
                            @foreach ($roles as $roleName)
                                <option value="{{ $roleName }}"
                                    {{ request('role') == $roleName ? 'selected' : '' }}>
                                    {{ ucfirst($roleName) }}
                                </option>
                            @endforeach
                        </select>
                    </x-filter-toolbar>
                </form>
            </div>

            {{-- Assigned Users Table --}}
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100">
                <div class="overflow-x-auto">
                    <table class="min-w-full divide-y divide-gray-100">
                        <thead class="bg-gray-50">
                            <tr>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Login Identity') }}</th>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Representing Business') }}</th>
                                <th
                                    class="px-6 py-4 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Status') }}</th>
                                <th
                                    class="px-6 py-4 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Actions') }}</th>
                            </tr>
                        </thead>
                        <tbody class="bg-white divide-y divide-gray-50">
                            @forelse ($users as $user)
                                <tr class="hover:bg-gray-50/50 transition-colors">
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        <div class="flex flex-col">
                                            <span class="text-sm font-bold text-gray-900">{{ $user->name }}</span>
                                            <span
                                                class="text-[10px] font-black text-blue-500 uppercase tracking-tighter">{{ $user->login_id }}</span>
                                        </div>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        @if ($user->company)
                                            <div class="flex flex-col">
                                                <div class="flex items-center gap-2">
                                                    <span
                                                        class="text-xs font-bold text-gray-700">{{ $user->company->company_name }}</span>
                                                    {{-- Visual Tag for HQ/Branch status based on Company hierarchy --}}
                                                    @if (is_null($user->company->parent_id))
                                                        <span
                                                            class="px-1.5 py-0.5 bg-blue-600 text-white rounded text-[8px] font-black uppercase">{{ __('HQ') }}</span>
                                                    @else
                                                        <span
                                                            class="px-1.5 py-0.5 bg-gray-100 text-gray-500 border border-gray-200 rounded text-[8px] font-black uppercase">{{ __('Branch') }}</span>
                                                    @endif
                                                </div>
                                                <span class="text-[10px] font-mono text-gray-400 uppercase">
                                                    {{ $user->company->company_code ?? $user->company->branch_code }}
                                                </span>
                                            </div>
                                        @else
                                            <span
                                                class="text-[10px] text-red-400 font-black uppercase italic">{{ __('Company Unassigned') }}</span>
                                        @endif
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap">
                                        <span
                                            class="inline-flex items-center px-2.5 py-0.5 rounded-full text-[10px] font-black uppercase {{ $user->status === 'active' ? 'bg-green-100 text-green-700' : 'bg-red-100 text-red-700' }}">
                                            {{ $user->status }}
                                        </span>
                                    </td>
                                    <td class="px-6 py-4 whitespace-nowrap text-right">
                                        <a href="{{ route('users.edit', $user) }}"
                                            class="inline-flex items-center bg-white border border-gray-200 text-gray-700 px-4 py-2 rounded-xl text-[10px] font-black uppercase hover:bg-gray-50 transition shadow-sm">
                                            {{ __('Edit Login') }}
                                        </a>
                                    </td>
                                </tr>
                            @empty
                                <tr>
                                    <td colspan="4" class="px-6 py-12 text-center">
                                        <p class="text-gray-400 text-xs font-bold uppercase tracking-widest">
                                            {{ __('No assigned customers found.') }}</p>
                                    </td>
                                </tr>
                            @endforelse
                        </tbody>
                    </table>
                </div>
                @if ($users->hasPages())
                    <div class="p-6 bg-gray-50 border-t border-gray-100">
                        {{ $users->links() }}
                    </div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/users/edit.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Edit User Credentials') }}
            </h2>
            <div class="flex items-center gap-3">
                <span class="text-xs font-black text-gray-400 uppercase tracking-widest">{{ $user->name }}
                    ({{ $user->login_id }})</span>
            </div>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-4xl mx-auto sm:px-6 lg:px-8 space-y-8">
            <form method="POST" action="{{ route('users.update', $user) }}" class="space-y-8">
                @csrf
                @method('PUT')

                {{-- SECTION 1: IDENTITY & BUSINESS ASSIGNMENT --}}
                <div class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100 p-8">
                    <div
                        class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest flex items-center gap-2">
                        <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                            stroke-width="2.5">
                            <path
                                d="M15 7a2 2 0 012 2m4 0a6 6 0 01-7.743 5.743L11 17H9v2H7v2H4a1 1 0 01-1-1v-2.586a1 1 0.293-.707l5.964-5.964A6 6 0 1121 9z" />
                        </svg>
                        {{ __('System Identity & Business Assignment') }}
                    </div>

                    <div class="grid grid-cols-1 md:grid-cols-2 gap-8 mb-8">
                        {{-- Locked Login ID --}}
                        <div>
                            <x-input-label for="login_id" :value="__('Login Identity (Locked)')"
                                class="text-[10px] font-black uppercase text-gray-400" />
                            <div class="mt-2 flex items-center gap-2">
                                <span
                                    class="text-sm font-mono font-bold text-gray-400 uppercase tracking-tighter">{{ $user->login_id }}</span>
                                <svg class="w-3 h-3 text-gray-300" fill="none" viewBox="0 0 24 24"
                                    stroke="currentColor">
                                    <path
                                        d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                                </svg>
                            </div>
                        </div>

                        {{-- Locked System Role --}}
                        <div>
                            <x-input-label for="role" :value="__('Account Authority (Locked)')"
                                class="text-[10px] font-black uppercase text-gray-400" />
                            <div class="mt-2">
                                <span
                                    class="px-3 py-1.5 bg-white border border-gray-200 rounded-xl text-xs font-black uppercase text-gray-400 shadow-sm inline-flex items-center gap-2">
                                    {{ str_replace('_', ' ', $user->roles->first()->name ?? 'N/A') }}
                                </span>
                                <input type="hidden" name="role" value="{{ $user->roles->first()->name }}">
                            </div>
                        </div>
                    </div>

                    {{-- Searchable Company Assignment [Addendum 2.a & 3.d] --}}
                    <div class="space-y-2">
                        <x-input-label for="company_id" :value="__('Assigned Business (Searchable)')"
                            class="text-[10px] font-black uppercase text-blue-600" />
                        <select name="company_id" id="company_id"
                            class="w-full border-gray-300 rounded-xl shadow-sm focus:ring-blue-500 text-sm @if ($isAssignmentLocked) bg-gray-50 cursor-not-allowed @endif"
                            @if ($isAssignmentLocked) disabled @endif>
                            <option value="">{{ __('-- Select Business Entity --') }}</option>
                            @foreach ($companys as $company)
                                <option value="{{ $company->id }}"
                                    {{ old('company_id', $user->company_id) == $company->id ? 'selected' : '' }}>
                                    {{ $company->company_name }}
                                    ({{ $company->company_code ?? $company->branch_code }})
                                </option>
                            @endforeach
                        </select>

                        @if ($isAssignmentLocked)
                            {{-- ARCHITECTURE: Hidden field prevents data loss on submit since select is disabled --}}
                            <input type="hidden" name="company_id" value="{{ $user->company_id }}">
                            <p class="text-[9px] font-black text-amber-600 uppercase italic mt-2">
                                {{ __('⚠️ Assignment Locked: Transaction history exists for this account. Relocation to a new business entity is restricted to maintain audit integrity.') }}
                            </p>
                        @else
                            <p class="mt-2 text-[9px] text-gray-400 italic uppercase">
                                {{ __('Strategic Alert: Changing the company assignment immediately updates this user\'s product visibility based on the new Company\'s Catalog.') }}
                            </p>
                        @endif
                    </div>
                </div>

                {{-- SECTION 2: PERSONAL INFORMATION --}}
                <div class="bg-white shadow-sm sm:rounded-3xl border border-gray-100 p-8">
                    <div class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                        {{ __('Personal Information') }}</div>
                    <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                        <div>
                            <x-input-label for="name" :value="__('Full Name')" class="text-[10px] font-black uppercase" />
                            <x-text-input id="name" name="name" type="text" class="mt-1 block w-full"
                                :value="old('name', $user->name)" required />
                        </div>
                        <div>
                            <x-input-label for="email" :value="__('Contact Email')" class="text-[10px] font-black uppercase" />
                            <x-text-input id="email" name="email" type="email" class="mt-1 block w-full"
                                :value="old('email', $user->email)" required />
                        </div>
                    </div>
                    <div class="mt-6">
                        <x-input-label for="status" :value="__('Credential Status')" class="text-[10px] font-black uppercase" />
                        <select name="status"
                            class="mt-1 block w-full border-gray-300 rounded-xl shadow-sm focus:ring-blue-500 text-sm font-bold uppercase">
                            <option value="active" {{ old('status', $user->status) === 'active' ? 'selected' : '' }}>
                                {{ __('Active') }}</option>
                            <option value="deactive"
                                {{ old('status', $user->status) === 'deactive' ? 'selected' : '' }}>
                                {{ __('Deactive') }}</option>
                        </select>
                    </div>
                </div>

                {{-- SECTION 3: SECURITY & OFFICE ASSIGNMENT --}}
                <div class="bg-white shadow-sm sm:rounded-3xl border border-gray-100 p-8">
                    <div class="text-[10px] font-black uppercase text-gray-400 mb-6 tracking-widest">
                        {{ __('Security & Office Assignment') }}</div>
                    <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                        <div>
                            <x-input-label for="password" :value="__('New Password')" class="text-[10px] font-black uppercase" />
                            <x-text-input id="password" name="password" type="password" class="mt-1 block w-full"
                                autocomplete="new-password" />
                        </div>
                        @can('reassign_customers')
                            <div>
                                <x-input-label for="assigned_cs_id" :value="__('Responsible CS Staff')"
                                    class="text-[10px] font-black uppercase" />
                                <select name="assigned_cs_id"
                                    class="mt-1 block w-full border-gray-300 rounded-xl shadow-sm text-sm">
                                    <option value="">{{ __('-- Unassigned --') }}</option>
                                    @foreach ($csStaffMembers as $cs)
                                        <option value="{{ $cs->id }}"
                                            {{ old('assigned_cs_id', $user->assigned_cs_id) == $cs->id ? 'selected' : '' }}>
                                            {{ $cs->name }} ({{ $cs->login_id }})
                                        </option>
                                    @endforeach
                                </select>
                            </div>
                        @endcan
                    </div>
                </div>

                <div class="flex items-center justify-end gap-4">
                    <a href="{{ route('users.index') }}"
                        class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">{{ __('Cancel') }}</a>
                    <x-primary-button
                        class="bg-blue-600 hover:bg-blue-700 py-3 px-10 rounded-2xl shadow-lg shadow-blue-100 transition-all uppercase text-[10px] font-black">
                        {{ __('Save Profile Changes') }}
                    </x-primary-button>
                </div>
            </form>

            @can('edit_users')
                <div
                    class="bg-red-50 p-8 rounded-3xl border border-red-100 flex flex-col md:flex-row justify-between items-center gap-6">
                    <div>
                        <h4 class="text-xs font-black text-red-600 uppercase tracking-widest">
                            {{ __('Dangerous: Permanent Removal') }}</h4>
                        <p class="text-[10px] text-red-400 mt-1 uppercase">
                            {{ __('Deleting an account is only possible if the user has never placed an order.') }}</p>
                    </div>
                    @if ($user->canBeDeleted())
                        <form method="POST" action="{{ route('users.destroy', $user) }}"
                            onsubmit="return confirm('{{ __('Are you absolutely sure? This will permanently wipe this login credential.') }}');">
                            @csrf @method('DELETE')
                            <button type="submit"
                                class="bg-red-600 hover:bg-red-700 text-white px-8 py-2.5 rounded-xl text-[10px] font-black uppercase transition shadow-lg shadow-red-100">
                                {{ __('Confirm Hard Delete') }}
                            </button>
                        </form>
                    @else
                        <div class="flex items-center gap-2" title="{{ __('Data integrity lock active') }}">
                            <svg class="w-4 h-4 text-red-300" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                                stroke-width="2.5">
                                <path
                                    d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                            </svg>
                            <span
                                class="text-[10px] font-black uppercase text-red-600">{{ __('Deletion Locked (Order History Found)') }}</span>
                        </div>
                    @endif
                </div>
            @endcan
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/users/create.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ $parent ? __('Add Branch for ') . $parent->name : __('Create New User Credential') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">
            {{-- ARCHITECTURE: Alpine state manages role-based conditional UI and searchable business mapping --}}
            <div x-data="{
                role: '{{ old('role', $parent ? 'customer' : '') }}',
                selectedId: '{{ old('company_id') }}',
                companys: @js($companys)
            }"
                class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100 p-8">

                <form method="POST" action="{{ route('users.store') }}" class="space-y-10">
                    @csrf

                    <!-- SECTION 1: ACCOUNT TYPE & CREDENTIALS [Addendum 3.b] -->
                    <div class="space-y-6">
                        <h3 class="text-[10px] font-black uppercase text-blue-600 mb-6 tracking-widest">
                            {{ __('Step 1: Identity & Role') }}</h3>

                        <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                            {{-- System Role Selection --}}
                            <div>
                                <x-input-label for="role" :value="__('System Access Role')"
                                    class="text-[10px] uppercase font-black" />
                                @php $isRestricted = auth()->user()->hasRole('cs_staff') || $parent; @endphp
                                <select name="role" id="role" x-model="role"
                                    class="block mt-1 w-full border-gray-300 rounded-xl shadow-sm @if ($isRestricted) bg-gray-50 cursor-not-allowed @endif"
                                    @if ($isRestricted) readonly @endif required>
                                    <option value="">{{ __('-- Select Account Type --') }}</option>
                                    @foreach ($roles as $roleOption)
                                        <option value="{{ $roleOption->name }}"
                                            {{ old('role') == $roleOption->name || ($parent && $roleOption->name == 'customer') ? 'selected' : '' }}>
                                            {{ ucfirst(str_replace('_', ' ', $roleOption->name)) }}
                                        </option>
                                    @endforeach
                                </select>
                                @if ($isRestricted)
                                    <input type="hidden" name="role" x-model="role">
                                @endif
                                <x-input-error :messages="$errors->get('role')" class="mt-2" />
                            </div>

                            {{-- Full Name --}}
                            <div>
                                <x-input-label for="name" :value="__('Full Name')"
                                    class="text-[10px] uppercase font-black" />
                                <x-text-input id="name" name="name" type="text" class="mt-1 block w-full"
                                    :value="old('name')" required />
                                <x-input-error :messages="$errors->get('name')" class="mt-2" />
                            </div>
                        </div>

                        <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                            {{-- Login ID --}}
                            <div>
                                <x-input-label for="login_id" :value="__('Login ID (Unique Username)')"
                                    class="text-[10px] uppercase font-black" />
                                <x-text-input id="login_id" name="login_id" type="text"
                                    class="mt-1 block w-full uppercase font-bold" :value="old('login_id')" required />
                                <x-input-error :messages="$errors->get('login_id')" class="mt-2" />
                            </div>

                            {{-- Email Address --}}
                            <div>
                                <x-input-label for="email" :value="__('Email Address')"
                                    class="text-[10px] uppercase font-black" />
                                <x-text-input id="email" name="email" type="email" class="mt-1 block w-full"
                                    :value="old('email')" required />
                                <x-input-error :messages="$errors->get('email')" class="mt-2" />
                            </div>
                        </div>
                    </div>

                    <!-- SECTION 2: SEARCHABLE BUSINESS ENTITY [Addendum 2.a, 3.d] -->
                    {{-- Fulfills requirement: Show ONLY if Role is 'customer' --}}
                    <div x-show="role === 'customer'" x-transition.duration.400ms
                        class="p-8 bg-blue-50 rounded-3xl border border-blue-100 space-y-6">
                        <div class="flex justify-between items-center">
                            <h3 class="text-[10px] font-black uppercase text-blue-600 tracking-widest">
                                {{ __('Step 2: Business Assignment') }}</h3>
                            <span
                                class="px-2 py-1 bg-blue-600 text-white text-[8px] font-black uppercase rounded">{{ __('Required for Customers') }}</span>
                        </div>

                        <div class="grid grid-cols-1 gap-6">
                            {{-- Searchable Company Logic --}}
                            <div>
                                <x-input-label for="company_search" :value="__('Assign to Business Entity (Search Name or Code)')"
                                    class="text-blue-800 font-black uppercase text-[10px]" />
                                <div class="mt-2 relative">
                                    <input list="company-list" id="company_search" name="company_name_display"
                                        class="w-full border-blue-200 rounded-xl focus:ring-blue-500 focus:border-blue-500 text-sm shadow-sm"
                                        placeholder="Type to search e.g. 'MaxTop HQ' or 'BR-001'..."
                                        @change="val = $event.target.value; let match = companys.find(c => c.company_name === val || (c.company_code && c.company_code === val) || (c.branch_code && c.branch_code === val)); if(match) selectedId = match.id;">
                                    <datalist id="company-list">
                                        @foreach ($companys as $company)
                                            <option value="{{ $company->company_name }}">
                                                {{ $company->company_code ?? $company->branch_code }}
                                            </option>
                                        @endforeach
                                    </datalist>

                                    {{-- Hidden input holds the actual foreign key for the 'users' table [3] --}}
                                    <input type="hidden" name="company_id" x-model="selectedId">
                                </div>
                                <x-input-error :messages="$errors->get('company_id')" class="mt-2" />
                                <p class="mt-3 text-[10px] text-blue-400 italic">
                                    {{ __('Architecture Note: Catalog visibility whitelists are derived from the selected Company.') }}
                                    [3, 4]
                                </p>
                            </div>

                            {{-- Responsible CS Assignment --}}
                            <div>
                                <x-input-label for="assigned_cs_id" :value="__('Designated Customer Service Representative')"
                                    class="text-[10px] uppercase font-black" />
                                <select name="assigned_cs_id" id="assigned_cs_id"
                                    class="mt-1 block w-full border-blue-200 rounded-xl shadow-sm text-sm">
                                    <option value="">{{ __('-- Auto-Assign / Unassigned --') }}</option>
                                    @foreach ($csStaffMembers as $cs)
                                        <option value="{{ $cs->id }}"
                                            {{ old('assigned_cs_id') == $cs->id || (!old('assigned_cs_id') && auth()->id() == $cs->id) ? 'selected' : '' }}>
                                            {{ $cs->name }} ({{ $cs->login_id }})
                                        </option>
                                    @endforeach
                                </select>
                            </div>
                        </div>
                    </div>

                    <!-- SECTION 3: SECURITY [Passwords] -->
                    <div class="space-y-6 pt-6 border-t border-gray-100">
                        <h3 class="text-[10px] font-black uppercase text-gray-400 tracking-widest">
                            {{ __('Step 3: Access Control') }}</h3>
                        <div class="grid grid-cols-1 md:grid-cols-2 gap-8">
                            <div>
                                <x-input-label for="password" :value="__('Initial Password')"
                                    class="text-[10px] uppercase font-black" />
                                <x-text-input id="password" name="password" type="password" class="mt-1 block w-full"
                                    required autocomplete="new-password" />
                                <x-input-error :messages="$errors->get('password')" class="mt-2" />
                            </div>
                            <div>
                                <x-input-label for="password_confirmation" :value="__('Confirm Password')"
                                    class="text-[10px] uppercase font-black" />
                                <x-text-input id="password_confirmation" name="password_confirmation" type="password"
                                    class="mt-1 block w-full" required />
                            </div>
                        </div>
                    </div>

                    <!-- SUBMIT ACTIONS -->
                    <div class="flex items-center justify-end pt-8 border-t border-gray-100 gap-4">
                        <a href="{{ auth()->user()->hasAnyRole(['admin', 'cs_leader'])? route('users.index'): route('users.assigned') }}"
                            class="text-xs font-black uppercase text-gray-400 hover:text-gray-600 transition tracking-widest">
                            {{ __('Cancel') }}
                        </a>
                        <x-primary-button
                            class="bg-blue-600 hover:bg-blue-700 py-4 px-10 rounded-2xl shadow-lg shadow-blue-200 transition-all uppercase text-[10px] font-black">
                            {{ __('Finalize Account Creation') }}
                        </x-primary-button>
                    </div>
                </form>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/customer/products/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex flex-col md:flex-row justify-between items-start md:items-center gap-4">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Available Products') }}
            </h2>

            {{-- Category Filter Toolbar --}}
            <div class="flex flex-wrap gap-2">
                <a href="{{ route('customer.products.index') }}"
                    class="px-4 py-2 rounded-full text-[10px] font-black uppercase transition-all border {{ !request('category') ? 'bg-blue-600 text-white border-blue-600 shadow-md shadow-blue-100' : 'bg-white text-gray-500 border-gray-100 hover:bg-gray-50' }}">
                    {{ __('All Items') }}
                </a>
                @foreach ($availableCategories as $cat)
                    <a href="{{ route('customer.products.index', ['category' => $cat->id]) }}"
                        class="px-4 py-2 rounded-full text-[10px] font-black uppercase transition-all border {{ request('category') == $cat->id ? 'bg-blue-600 text-white border-blue-600 shadow-md shadow-blue-100' : 'bg-white text-gray-500 border-gray-100 hover:bg-gray-50' }}">
                        {{ $cat->name }}
                    </a>
                @endforeach
            </div>
        </div>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8 space-y-8">

            {{-- Search Toolbar --}}
            <div class="bg-white p-6 rounded-[2rem] border border-gray-100 shadow-sm">
                <form method="GET" action="{{ route('customer.products.index') }}">
                    <x-filter-toolbar :placeholder="__('Search product name or SKU...')" :showDates="false">
                        @if (request('category'))
                            <input type="hidden" name="category" value="{{ request('category') }}">
                        @endif
                    </x-filter-toolbar>
                </form>
            </div>

            @if ($items->isEmpty())
                <div class="bg-white p-20 rounded-[3rem] border border-gray-100 text-center">
                    <div class="flex flex-col items-center">
                        <svg class="w-16 h-16 text-gray-200 mb-4" fill="none" viewBox="0 0 24 24"
                            stroke="currentColor" stroke-width="1.5">
                            <path d="M20 7l-8-4-8 4m16 0l-8 4m8-4v10l-8 4m0-10L4 7m8 4v10M4 7v10l8 4" />
                        </svg>
                        <p class="text-gray-400 font-black uppercase tracking-widest">
                            {{ __('No products found in your whitelist.') }}</p>
                    </div>
                </div>
            @else
                <div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-6">
                    @foreach ($items as $item)
                        <div
                            class="bg-white p-6 rounded-[2.5rem] border border-gray-100 shadow-sm flex flex-col hover:shadow-xl hover:shadow-blue-50 transition-all duration-300">
                            {{-- Product Identity --}}
                            <div class="relative mb-4">
                                @if ($item->image_path)
                                    <img src="{{ asset('storage/' . $item->image_path) }}"
                                        class="w-full h-48 object-cover rounded-[1.5rem] shadow-sm">
                                @else
                                    <div
                                        class="w-full h-48 bg-gray-50 flex items-center justify-center rounded-[1.5rem] border border-dashed border-gray-200">
                                        <span
                                            class="text-[10px] font-black text-gray-300 uppercase italic">{{ __('No Image') }}</span>
                                    </div>
                                @endif
                                <div class="absolute top-3 left-3">
                                    <span
                                        class="px-2 py-1 bg-white/90 backdrop-blur shadow-sm rounded-lg text-[9px] font-mono font-black text-blue-600 uppercase">
                                        {{ $item->sku }}
                                    </span>
                                </div>
                            </div>

                            <div class="flex-1">
                                <h3 class="text-sm font-black text-gray-900 leading-tight mb-1">{{ $item->name }}
                                </h3>
                                <p class="text-[10px] text-gray-400 line-clamp-2 mb-4 leading-relaxed italic">
                                    {{ $item->description ?? __('No detailed description available.') }}
                                </p>
                            </div>

                            {{-- Ordering Block --}}
                            <div class="mt-4 pt-4 border-t border-gray-50">
                                @if (auth()->user()->hasPendingOrder())
                                    <div class="bg-amber-50 border border-amber-100 p-3 rounded-2xl text-center">
                                        <span
                                            class="block text-[10px] text-amber-700 font-black uppercase tracking-tighter">{{ __('Order Pending Review') }}</span>
                                        <span
                                            class="block text-[8px] text-amber-600 mt-1 italic">{{ __('Recall pending order to enable edits.') }}</span>
                                    </div>
                                @else
                                    <form method="POST" action="{{ route('reservation.store') }}"
                                        x-data="{
                                            selectedUom: 'individual',
                                            hasUoms: {{ $item->activeUoms->count() > 0 ? 'true' : 'false' }},
                                            {{-- FIX: Map UOM IDs to object containing QTY and LABEL (with Rates) --}}
                                            draftMap: @js(
    $draftItems->where('item_id', $item->id)->mapWithKeys(
        fn($i) => [
            $i->uom_id ?? 'individual' => [
                'qty' => $i->quantity,
                // logic to show 'Box (x10)' or 'Individual Unit'
                'label' => $i->uom ? $i->uom->uom_name . ' (x' . $i->uom->rate_qty . ')' : __('Individual Unit'),
            ],
        ],
    ),
)
                                        }" class="space-y-4">
                                        @csrf
                                        <input type="hidden" name="item_id" value="{{ $item->id }}">

                                        <div>
                                            {{-- FIX: Iterate through ALL drafts in the map, regardless of dropdown selection --}}
                                            <div class="my-3 space-y-2 mt-2">
                                                <template x-for="(data, uomKey) in draftMap" :key="uomKey">
                                                    <div
                                                        class="px-3 py-2 bg-indigo-50 rounded-xl flex items-center justify-between border border-indigo-100 animate-pulse">
                                                        <span
                                                            class="text-[9px] font-black text-indigo-600 uppercase">{{ __('In My Draft: ') }}</span>
                                                        <span class="text-xs font-black text-indigo-700"
                                                            x-text="data.qty + ' ' + data.label">
                                                        </span>
                                                    </div>
                                                </template>
                                            </div>

                                            <x-input-label :value="__('Select Packaging Unit')"
                                                class="text-[9px] font-black text-gray-400 uppercase mb-1" />

                                            <select name="uom_id" x-model="selectedUom"
                                                :class="hasUoms ? 'bg-blue-50 border-blue-200 text-blue-700' :
                                                    'bg-gray-50 text-gray-400'"
                                                class="w-full rounded-xl text-xs font-bold transition-all focus:ring-blue-500">

                                                {{-- Added Individual Option for completeness --}}
                                                {{-- <option value="individual">{{ __('Individual Unit') }}</option> --}}

                                                @foreach ($item->activeUoms as $uom)
                                                    <option value="{{ $uom->id }}">{{ $uom->uom_name }}
                                                        (x{{ $uom->rate_qty }})
                                                    </option>
                                                @endforeach
                                            </select>
                                        </div>

                                        <div class="flex gap-2">
                                            <x-text-input name="quantity" type="number" value="1" min="1"
                                                max="999"
                                                class="w-20 rounded-xl border-gray-100 text-sm font-black text-center" />

                                            <x-primary-button
                                                class="flex-1 justify-center bg-blue-600 hover:bg-blue-700 py-2.5 rounded-xl text-[10px] font-black uppercase transition-all shadow-lg shadow-blue-100">
                                                {{ __('Add To Draft') }}
                                            </x-primary-button>
                                        </div>
                                    </form>
                                @endif
                            </div>
                        </div>
                    @endforeach
                </div>

                <div class="mt-12">
                    {{ $items->links() }}
                </div>
            @endif
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/customer/reservation/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
            {{ __('My Reservation Draft') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-5xl mx-auto sm:px-6 lg:px-8 space-y-6">

            @if (!$draft || $items->isEmpty())
                <div class="bg-white p-16 rounded-[2.5rem] border border-gray-100 shadow-sm text-center">
                    <div class="flex flex-col items-center">
                        <svg class="w-16 h-16 text-gray-200 mb-4" fill="none" viewBox="0 0 24 24" stroke="currentColor"
                            stroke-width="1.5">
                            <path d="M16 11V7a4 4 0 00-8 0v4M5 9h14l1 12H4L5 9z" />
                        </svg>
                        <p class="text-gray-400 font-black uppercase tracking-widest text-sm">
                            {{ __('Your draft is currently empty') }}</p>
                        <a href="{{ route('customer.products.index') }}"
                            class="mt-6 inline-flex items-center px-6 py-3 bg-blue-600 hover:bg-blue-700 text-white rounded-2xl text-xs font-black uppercase transition-all shadow-lg shadow-blue-100">
                            {{ __('Browse Product Catalog') }}
                        </a>
                    </div>
                </div>
            @else
                @php
                    // ARCHITECTURE: Group by item_id to cluster different packaging types under SKU [Backbone 4.a.2]
                    $groupedItems = $items->groupBy('item_id');
                    $totalQty = $items->sum('quantity');
                @endphp

                <div class="bg-white shadow-sm sm:rounded-[2.5rem] border border-gray-100 overflow-hidden">
                    <table class="min-w-full divide-y divide-gray-100">
                        <thead class="bg-gray-50">
                            <tr>
                                <th
                                    class="px-8 py-5 text-left text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Product Details') }}</th>
                                <th
                                    class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Selected Unit') }}</th>
                                <th
                                    class="px-6 py-5 text-center text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Quantity') }}</th>
                                <th
                                    class="px-8 py-5 text-right text-[10px] font-black text-gray-400 uppercase tracking-widest">
                                    {{ __('Management') }}</th>
                            </tr>
                        </thead>
                        <tbody class="divide-y divide-gray-50 bg-white">
                            @foreach ($groupedItems as $itemId => $entries)
                                @php $masterItem = $entries->first()->item; @endphp

                                {{-- SKU Group Header --}}
                                <tr class="bg-blue-50/30">
                                    <td colspan="4" class="px-8 py-3 border-y border-blue-100/50">
                                        <div class="flex items-center gap-3">
                                            <span
                                                class="px-2 py-0.5 bg-blue-600 text-white text-[9px] font-mono font-black rounded uppercase tracking-tighter">
                                                {{ $masterItem->sku }}
                                            </span>
                                            <span
                                                class="text-xs font-black text-gray-900 uppercase tracking-tight">{{ $masterItem->name }}</span>
                                        </div>
                                    </td>
                                </tr>

                                @foreach ($entries as $orderItem)
                                    <tr class="hover:bg-gray-50/50 transition-colors">
                                        <td class="px-8 py-4"></td>
                                        <td class="px-6 py-4 text-center">
                                            {{-- STRICT UOM: Display packaging name and rate [Addendum 5.a] --}}
                                            <span
                                                class="px-3 py-1 rounded-full text-[10px] font-black uppercase tracking-tight bg-blue-100 text-blue-700 border border-blue-200">
                                                {{ $orderItem->uom->uom_name }} (x{{ $orderItem->uom->rate_qty }})
                                            </span>
                                        </td>
                                        <td class="px-6 py-4">
                                            <form method="POST" action="{{ route('reservation.update', $orderItem) }}"
                                                class="flex items-center justify-center gap-3">
                                                @csrf
                                                @method('PUT')
                                                <input type="number" name="quantity"
                                                    value="{{ $orderItem->quantity }}" min="1" max="999"
                                                    class="w-20 text-center border-gray-200 rounded-xl text-sm font-black focus:ring-blue-500">
                                                <button type="submit" title="{{ __('Update Quantity') }}"
                                                    class="text-blue-500 hover:text-blue-700 transition-transform active:scale-90">
                                                    <svg class="w-5 h-5" fill="none" viewBox="0 0 24 24"
                                                        stroke="currentColor" stroke-width="3">
                                                        <path d="M5 13l4 4L19 7" />
                                                    </svg>
                                                </button>
                                            </form>
                                        </td>
                                        <td class="px-8 py-4 text-right">
                                            <form method="POST"
                                                action="{{ route('reservation.destroy', $orderItem) }}"
                                                onsubmit="return confirm('{{ __('Remove this item from your draft?') }}');">
                                                @csrf
                                                @method('DELETE')
                                                <button type="submit"
                                                    class="text-red-400 hover:text-red-600 text-[10px] font-black uppercase tracking-widest transition-colors">
                                                    {{ __('Remove') }}
                                                </button>
                                            </form>
                                        </td>
                                    </tr>
                                @endforeach
                            @endforeach
                        </tbody>
                    </table>

                    {{-- Price Blind Footer: Volume-based reservation [Backbone 4.b, 120] --}}
                    <div class="p-10 bg-gray-900 flex flex-col md:flex-row justify-between items-center gap-8">
                        <div class="flex flex-col text-center md:text-left">
                            <span
                                class="text-[10px] font-black uppercase text-gray-500 tracking-[0.2em] mb-1">{{ __('Total Reservation Volume') }}</span>
                            <div class="flex items-baseline gap-2">
                                <span class="text-4xl font-black text-white leading-none">{{ $totalQty }}</span>
                                <span
                                    class="text-sm font-bold text-gray-500 uppercase tracking-widest">{{ __('Units') }}</span>
                            </div>
                        </div>

                        <form method="POST" action="{{ route('reservation.submit') }}"
                            onsubmit="return confirm('{{ __('Ready to submit for CS review?') }}');">
                            @csrf
                            <button type="submit"
                                class="bg-green-600 hover:bg-green-700 text-white py-5 px-14 rounded-2xl text-sm font-black uppercase shadow-xl shadow-green-900/40 transition-all hover:-translate-y-1">
                                {{ __('Submit for Review') }}
                            </button>
                        </form>
                    </div>
                </div>

                <div class="flex items-center justify-center gap-2 text-gray-400">
                    <svg class="w-4 h-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2">
                        <path
                            d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z" />
                    </svg>
                    <span
                        class="text-[9px] font-black uppercase tracking-widest">{{ __('Prices are hidden for B2B confidentiality and validated during CS approval') }}</span>
                </div>
            @endif
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/customer/orders/index.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <h2 class="font-semibold text-xl text-gray-800 leading-tight">
            {{ __('My Order History') }}
        </h2>
    </x-slot>

    <div class="py-12">
        <div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
            <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg p-6">
                @if ($orders->isEmpty())
                    <div class="text-center py-8">
                        <p class="text-gray-500 italic">{{ __('You have no past orders yet.') }}</p>
                    </div>
                @else
                    <div class="overflow-x-auto">
                        <table class="w-full text-left border-collapse">
                            <thead>
                                <tr class="bg-gray-50 border-b">
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Order #') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">
                                        {{ __('Date Submitted') }}</th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600">{{ __('Status') }}
                                    </th>
                                    <th class="px-4 py-3 text-xs font-bold uppercase text-gray-600 text-right">
                                        {{ __('Action') }}</th>
                                </tr>
                            </thead>
                            <tbody>
                                @foreach ($orders as $order)
                                    <tr class="border-b hover:bg-gray-50 transition-colors">
                                        <td class="px-4 py-4 font-mono font-bold text-sm text-blue-600">
                                            {{ $order->order_number ?? 'Processing...' }}
                                        </td>
                                        <td class="px-4 py-4 text-sm text-gray-600">
                                            {{ $order->created_at->format('Y-m-d H:i') }}
                                        </td>
                                        <td class="px-4 py-4">
                                            <span
                                                class="px-2 py-1 rounded-full text-[10px] font-black uppercase shadow-sm
                                                @if ($order->status === 'pending') bg-yellow-100 text-yellow-800 border border-yellow-300
                                                @elseif($order->status === 'approved') bg-green-100 text-green-800 border border-green-300
                                                @elseif($order->status === 'cancelled') bg-red-100 text-red-800 border border-red-300
                                                @else bg-blue-100 text-blue-800 border border-blue-300 @endif">
                                                {{ $order->status }}
                                            </span>
                                        </td>
                                        <td class="px-4 py-4 text-right">
                                            <a href="{{ route('customer.orders.show', $order) }}"
                                                class="text-blue-600 font-bold hover:underline text-sm">
                                                {{ __('View Details') }}
                                            </a>
                                        </td>
                                    </tr>
                                @endforeach
                            </tbody>
                        </table>
                    </div>
                    <div class="mt-4">
                        {{ $orders->links() }}
                    </div>
                @endif
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/resources/views/customer/orders/show.blade.php ---
<x-app-layout>
    <x-slot name="header">
        <div class="flex justify-between items-center">
            <h2 class="font-black text-xl text-gray-800 leading-tight uppercase tracking-tight">
                {{ __('Order Details') }}: {{ $order->order_number }}
            </h2>
            <a href="{{ route('customer.orders.index') }}" class="text-xs font-bold text-blue-600 uppercase">←
                {{ __('Back to History') }}</a>
        </div>
    </x-slot>

    <div class="py-12">
        {{-- Fulfills Request: Recall functionality --}}
        @if ($order->status === 'pending')
            <form action="{{ route('reservation.recall', $order) }}" method="POST"
                onsubmit="return confirm('Move this order back to draft for editing?');">
                @csrf
                <button type="submit"
                    class="bg-orange-500 hover:bg-orange-600 text-white px-4 py-2 rounded-lg text-xs font-black uppercase transition shadow-md">
                    {{ __('Recall to Draft') }}
                </button>
            </form>
        @endif
        <div class="max-w-5xl mx-auto sm:px-6 lg:px-8 space-y-6">
            @php
                // Group by item_id to handle different UOMs for the same SKU [Addendum 5.a]
                $groupedItems = $order->items->groupBy('item_id');
                $totalQty = $order->items->sum('quantity');
            @endphp

            <div class="bg-white overflow-hidden shadow-sm sm:rounded-3xl border border-gray-100">
                <table class="min-w-full divide-y divide-gray-100">
                    <thead class="bg-gray-50">
                        <tr>
                            <th class="px-8 py-4 text-left text-[10px] font-black text-gray-400 uppercase">
                                {{ __('Item Description') }}</th>
                            <th class="px-6 py-4 text-center text-[10px] font-black text-gray-400 uppercase">
                                {{ __('Packaging Unit') }}</th>
                            <th class="px-6 py-4 text-center text-[10px] font-black text-gray-400 uppercase">
                                {{ __('Quantity') }}</th>
                        </tr>
                    </thead>
                    <tbody class="divide-y divide-gray-50">
                        @foreach ($groupedItems as $itemId => $entries)
                            @php $masterItem = $entries->first()->item; @endphp
                            <tr class="bg-blue-50/20">
                                <td colspan="3" class="px-8 py-3">
                                    <div class="flex items-center gap-2">
                                        <span
                                            class="text-[10px] font-mono font-black bg-blue-600 text-white px-2 py-0.5 rounded">{{ $masterItem->sku }}</span>
                                        <span class="text-xs font-bold text-gray-900">{{ $masterItem->name }}</span>
                                    </div>
                                </td>
                            </tr>
                            @foreach ($entries as $item)
                                <tr>
                                    <td></td>
                                    <td class="px-6 py-4 text-center">
                                        {{-- ARCHITECTURE: Distinguish between UOM and Individual [4] --}}
                                        <span
                                            class="px-3 py-1 rounded-lg text-[10px] font-black uppercase {{ $item->uom_id ? 'bg-blue-100 text-blue-700' : 'bg-gray-100 text-gray-600' }}">
                                            {{ $item->uom?->uom_name ?? __('Individual Unit') }}
                                        </span>
                                    </td>
                                    <td class="px-6 py-4 text-center text-sm font-bold text-gray-700">
                                        {{ $item->quantity }}
                                    </td>
                                </tr>
                            @endforeach
                        @endforeach
                    </tbody>
                </table>

                {{-- Footer: Fulfills Price Blind Policy [4.b] --}}
                <div class="p-8 bg-gray-900 text-white flex justify-between items-center">
                    <div>
                        <p class="text-[10px] font-black uppercase text-gray-500 tracking-widest">
                            {{ __('Total Order Volume') }}</p>
                        <p class="text-2xl font-black">{{ $totalQty }} <span
                                class="text-sm font-bold text-gray-500 uppercase">{{ __('Units') }}</span></p>
                    </div>
                    <div class="text-right">
                        <span
                            class="px-4 py-2 bg-blue-600/20 border border-blue-500/30 rounded-xl text-[10px] font-black uppercase text-blue-400">
                            {{ $order->status }}
                        </span>
                    </div>
                </div>
            </div>
        </div>
    </div>
</x-app-layout>

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/vite.config.js ---
import { defineConfig } from 'vite';
import laravel from 'laravel-vite-plugin';

export default defineConfig({
    plugins: [
        laravel({
            input: ['resources/css/app.css', 'resources/js/app.js'],
            refresh: true,
        }),
    ],
});

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/README.md ---
<p align="center"><a href="https://laravel.com" target="_blank"><img src="https://raw.githubusercontent.com/laravel/art/master/logo-lockup/5%20SVG/2%20CMYK/1%20Full%20Color/laravel-logolockup-cmyk-red.svg" width="400" alt="Laravel Logo"></a></p>

<p align="center">
<a href="https://github.com/laravel/framework/actions"><img src="https://github.com/laravel/framework/workflows/tests/badge.svg" alt="Build Status"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/dt/laravel/framework" alt="Total Downloads"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/v/laravel/framework" alt="Latest Stable Version"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/l/laravel/framework" alt="License"></a>
</p>

## About Laravel

Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:

- [Simple, fast routing engine](https://laravel.com/docs/routing).
- [Powerful dependency injection container](https://laravel.com/docs/container).
- Multiple back-ends for [session](https://laravel.com/docs/session) and [cache](https://laravel.com/docs/cache) storage.
- Expressive, intuitive [database ORM](https://laravel.com/docs/eloquent).
- Database agnostic [schema migrations](https://laravel.com/docs/migrations).
- [Robust background job processing](https://laravel.com/docs/queues).
- [Real-time event broadcasting](https://laravel.com/docs/broadcasting).

Laravel is accessible, powerful, and provides tools required for large, robust applications.

## Learning Laravel

Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework. You can also check out [Laravel Learn](https://laravel.com/learn), where you will be guided through building a modern Laravel application.

If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains thousands of video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.

## Laravel Sponsors

We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the [Laravel Partners program](https://partners.laravel.com).

### Premium Partners

- **[Vehikl](https://vehikl.com)**
- **[Tighten Co.](https://tighten.co)**
- **[Kirschbaum Development Group](https://kirschbaumdevelopment.com)**
- **[64 Robots](https://64robots.com)**
- **[Curotec](https://www.curotec.com/services/technologies/laravel)**
- **[DevSquad](https://devsquad.com/hire-laravel-developers)**
- **[Redberry](https://redberry.international/laravel-development)**
- **[Active Logic](https://activelogic.com)**

## Contributing

Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions).

## Code of Conduct

In order to ensure that the Laravel community is welcoming to all, please review and abide by the [Code of Conduct](https://laravel.com/docs/contributions#code-of-conduct).

## Security Vulnerabilities

If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [taylor@laravel.com](mailto:taylor@laravel.com). All security vulnerabilities will be promptly addressed.

## License

The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).

##

## Update details(v22)(CYW)

- Solve:
  ** Change the “price” to “status” at the staff side item list table.
  ** “Create item” & “Edit item” page change the “Display name” to “Product name”.
  ** Accessing the “Feature Settings” page will cause an error.
  ** CS Staff access page “My Customer” > “Edit Login” will hit error 403.
  \*\* CS Staff missing "Business Entities".

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/package-lock.json ---
{
    "name": "Maxtop e-ordering system",
    "lockfileVersion": 3,
    "requires": true,
    "packages": {
        "": {
            "devDependencies": {
                "@tailwindcss/forms": "^0.5.2",
                "@tailwindcss/vite": "^4.0.0",
                "alpinejs": "^3.4.2",
                "autoprefixer": "^10.4.2",
                "axios": "^1.11.0",
                "concurrently": "^9.0.1",
                "laravel-vite-plugin": "^2.0.0",
                "postcss": "^8.4.31",
                "prettier-plugin-blade": "^2.1.21",
                "tailwindcss": "^3.1.0",
                "vite": "^7.0.7"
            }
        },
        "node_modules/@alloc/quick-lru": {
            "version": "5.2.0",
            "resolved": "https://registry.npmjs.org/@alloc/quick-lru/-/quick-lru-5.2.0.tgz",
            "integrity": "sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw==",
            "dev": true,
            "engines": {
                "node": ">=10"
            },
            "funding": {
                "url": "https://github.com/sponsors/sindresorhus"
            }
        },
        "node_modules/@esbuild/aix-ppc64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.27.2.tgz",
            "integrity": "sha512-GZMB+a0mOMZs4MpDbj8RJp4cw+w1WV5NYD6xzgvzUJ5Ek2jerwfO2eADyI6ExDSUED+1X8aMbegahsJi+8mgpw==",
            "cpu": [
                "ppc64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "aix"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/android-arm": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.27.2.tgz",
            "integrity": "sha512-DVNI8jlPa7Ujbr1yjU2PfUSRtAUZPG9I1RwW4F4xFB1Imiu2on0ADiI/c3td+KmDtVKNbi+nffGDQMfcIMkwIA==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/android-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.27.2.tgz",
            "integrity": "sha512-pvz8ZZ7ot/RBphf8fv60ljmaoydPU12VuXHImtAs0XhLLw+EXBi2BLe3OYSBslR4rryHvweW5gmkKFwTiFy6KA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/android-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.27.2.tgz",
            "integrity": "sha512-z8Ank4Byh4TJJOh4wpz8g2vDy75zFL0TlZlkUkEwYXuPSgX8yzep596n6mT7905kA9uHZsf/o2OJZubl2l3M7A==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/darwin-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.27.2.tgz",
            "integrity": "sha512-davCD2Zc80nzDVRwXTcQP/28fiJbcOwvdolL0sOiOsbwBa72kegmVU0Wrh1MYrbuCL98Omp5dVhQFWRKR2ZAlg==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/darwin-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.27.2.tgz",
            "integrity": "sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/freebsd-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.27.2.tgz",
            "integrity": "sha512-lS/9CN+rgqQ9czogxlMcBMGd+l8Q3Nj1MFQwBZJyoEKI50XGxwuzznYdwcav6lpOGv5BqaZXqvBSiB/kJ5op+g==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/freebsd-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.27.2.tgz",
            "integrity": "sha512-tAfqtNYb4YgPnJlEFu4c212HYjQWSO/w/h/lQaBK7RbwGIkBOuNKQI9tqWzx7Wtp7bTPaGC6MJvWI608P3wXYA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-arm": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.27.2.tgz",
            "integrity": "sha512-vWfq4GaIMP9AIe4yj1ZUW18RDhx6EPQKjwe7n8BbIecFtCQG4CfHGaHuh7fdfq+y3LIA2vGS/o9ZBGVxIDi9hw==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.27.2.tgz",
            "integrity": "sha512-hYxN8pr66NsCCiRFkHUAsxylNOcAQaxSSkHMMjcpx0si13t1LHFphxJZUiGwojB1a/Hd5OiPIqDdXONia6bhTw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-ia32": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.27.2.tgz",
            "integrity": "sha512-MJt5BRRSScPDwG2hLelYhAAKh9imjHK5+NE/tvnRLbIqUWa+0E9N4WNMjmp/kXXPHZGqPLxggwVhz7QP8CTR8w==",
            "cpu": [
                "ia32"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-loong64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.27.2.tgz",
            "integrity": "sha512-lugyF1atnAT463aO6KPshVCJK5NgRnU4yb3FUumyVz+cGvZbontBgzeGFO1nF+dPueHD367a2ZXe1NtUkAjOtg==",
            "cpu": [
                "loong64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-mips64el": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.27.2.tgz",
            "integrity": "sha512-nlP2I6ArEBewvJ2gjrrkESEZkB5mIoaTswuqNFRv/WYd+ATtUpe9Y09RnJvgvdag7he0OWgEZWhviS1OTOKixw==",
            "cpu": [
                "mips64el"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-ppc64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.27.2.tgz",
            "integrity": "sha512-C92gnpey7tUQONqg1n6dKVbx3vphKtTHJaNG2Ok9lGwbZil6DrfyecMsp9CrmXGQJmZ7iiVXvvZH6Ml5hL6XdQ==",
            "cpu": [
                "ppc64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-riscv64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.27.2.tgz",
            "integrity": "sha512-B5BOmojNtUyN8AXlK0QJyvjEZkWwy/FKvakkTDCziX95AowLZKR6aCDhG7LeF7uMCXEJqwa8Bejz5LTPYm8AvA==",
            "cpu": [
                "riscv64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-s390x": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.27.2.tgz",
            "integrity": "sha512-p4bm9+wsPwup5Z8f4EpfN63qNagQ47Ua2znaqGH6bqLlmJ4bx97Y9JdqxgGZ6Y8xVTixUnEkoKSHcpRlDnNr5w==",
            "cpu": [
                "s390x"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/linux-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.27.2.tgz",
            "integrity": "sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/netbsd-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.27.2.tgz",
            "integrity": "sha512-Kj6DiBlwXrPsCRDeRvGAUb/LNrBASrfqAIok+xB0LxK8CHqxZ037viF13ugfsIpePH93mX7xfJp97cyDuTZ3cw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "netbsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/netbsd-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.27.2.tgz",
            "integrity": "sha512-HwGDZ0VLVBY3Y+Nw0JexZy9o/nUAWq9MlV7cahpaXKW6TOzfVno3y3/M8Ga8u8Yr7GldLOov27xiCnqRZf0tCA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "netbsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/openbsd-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.27.2.tgz",
            "integrity": "sha512-DNIHH2BPQ5551A7oSHD0CKbwIA/Ox7+78/AWkbS5QoRzaqlev2uFayfSxq68EkonB+IKjiuxBFoV8ESJy8bOHA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "openbsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/openbsd-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.27.2.tgz",
            "integrity": "sha512-/it7w9Nb7+0KFIzjalNJVR5bOzA9Vay+yIPLVHfIQYG/j+j9VTH84aNB8ExGKPU4AzfaEvN9/V4HV+F+vo8OEg==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "openbsd"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/openharmony-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.27.2.tgz",
            "integrity": "sha512-LRBbCmiU51IXfeXk59csuX/aSaToeG7w48nMwA6049Y4J4+VbWALAuXcs+qcD04rHDuSCSRKdmY63sruDS5qag==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "openharmony"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/sunos-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.27.2.tgz",
            "integrity": "sha512-kMtx1yqJHTmqaqHPAzKCAkDaKsffmXkPHThSfRwZGyuqyIeBvf08KSsYXl+abf5HDAPMJIPnbBfXvP2ZC2TfHg==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "sunos"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/win32-arm64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.27.2.tgz",
            "integrity": "sha512-Yaf78O/B3Kkh+nKABUF++bvJv5Ijoy9AN1ww904rOXZFLWVc5OLOfL56W+C8F9xn5JQZa3UX6m+IktJnIb1Jjg==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/win32-ia32": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.27.2.tgz",
            "integrity": "sha512-Iuws0kxo4yusk7sw70Xa2E2imZU5HoixzxfGCdxwBdhiDgt9vX9VUCBhqcwY7/uh//78A1hMkkROMJq9l27oLQ==",
            "cpu": [
                "ia32"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@esbuild/win32-x64": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.27.2.tgz",
            "integrity": "sha512-sRdU18mcKf7F+YgheI/zGf5alZatMUTKj/jNS6l744f9u3WFu4v7twcUI9vu4mknF4Y9aDlblIie0IM+5xxaqQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">=18"
            }
        },
        "node_modules/@jridgewell/gen-mapping": {
            "version": "0.3.13",
            "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz",
            "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==",
            "dev": true,
            "dependencies": {
                "@jridgewell/sourcemap-codec": "^1.5.0",
                "@jridgewell/trace-mapping": "^0.3.24"
            }
        },
        "node_modules/@jridgewell/remapping": {
            "version": "2.3.5",
            "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz",
            "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==",
            "dev": true,
            "dependencies": {
                "@jridgewell/gen-mapping": "^0.3.5",
                "@jridgewell/trace-mapping": "^0.3.24"
            }
        },
        "node_modules/@jridgewell/resolve-uri": {
            "version": "3.1.2",
            "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz",
            "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==",
            "dev": true,
            "engines": {
                "node": ">=6.0.0"
            }
        },
        "node_modules/@jridgewell/sourcemap-codec": {
            "version": "1.5.5",
            "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz",
            "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==",
            "dev": true
        },
        "node_modules/@jridgewell/trace-mapping": {
            "version": "0.3.31",
            "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz",
            "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==",
            "dev": true,
            "dependencies": {
                "@jridgewell/resolve-uri": "^3.1.0",
                "@jridgewell/sourcemap-codec": "^1.4.14"
            }
        },
        "node_modules/@nodelib/fs.scandir": {
            "version": "2.1.5",
            "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
            "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
            "dev": true,
            "dependencies": {
                "@nodelib/fs.stat": "2.0.5",
                "run-parallel": "^1.1.9"
            },
            "engines": {
                "node": ">= 8"
            }
        },
        "node_modules/@nodelib/fs.stat": {
            "version": "2.0.5",
            "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
            "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
            "dev": true,
            "engines": {
                "node": ">= 8"
            }
        },
        "node_modules/@nodelib/fs.walk": {
            "version": "1.2.8",
            "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
            "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
            "dev": true,
            "dependencies": {
                "@nodelib/fs.scandir": "2.1.5",
                "fastq": "^1.6.0"
            },
            "engines": {
                "node": ">= 8"
            }
        },
        "node_modules/@rollup/rollup-android-arm-eabi": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.54.0.tgz",
            "integrity": "sha512-OywsdRHrFvCdvsewAInDKCNyR3laPA2mc9bRYJ6LBp5IyvF3fvXbbNR0bSzHlZVFtn6E0xw2oZlyjg4rKCVcng==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ]
        },
        "node_modules/@rollup/rollup-android-arm64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.54.0.tgz",
            "integrity": "sha512-Skx39Uv+u7H224Af+bDgNinitlmHyQX1K/atIA32JP3JQw6hVODX5tkbi2zof/E69M1qH2UoN3Xdxgs90mmNYw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ]
        },
        "node_modules/@rollup/rollup-darwin-arm64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.54.0.tgz",
            "integrity": "sha512-k43D4qta/+6Fq+nCDhhv9yP2HdeKeP56QrUUTW7E6PhZP1US6NDqpJj4MY0jBHlJivVJD5P8NxrjuobZBJTCRw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ]
        },
        "node_modules/@rollup/rollup-darwin-x64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.54.0.tgz",
            "integrity": "sha512-cOo7biqwkpawslEfox5Vs8/qj83M/aZCSSNIWpVzfU2CYHa2G3P1UN5WF01RdTHSgCkri7XOlTdtk17BezlV3A==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ]
        },
        "node_modules/@rollup/rollup-freebsd-arm64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.54.0.tgz",
            "integrity": "sha512-miSvuFkmvFbgJ1BevMa4CPCFt5MPGw094knM64W9I0giUIMMmRYcGW/JWZDriaw/k1kOBtsWh1z6nIFV1vPNtA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ]
        },
        "node_modules/@rollup/rollup-freebsd-x64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.54.0.tgz",
            "integrity": "sha512-KGXIs55+b/ZfZsq9aR026tmr/+7tq6VG6MsnrvF4H8VhwflTIuYh+LFUlIsRdQSgrgmtM3fVATzEAj4hBQlaqQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ]
        },
        "node_modules/@rollup/rollup-linux-arm-gnueabihf": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.54.0.tgz",
            "integrity": "sha512-EHMUcDwhtdRGlXZsGSIuXSYwD5kOT9NVnx9sqzYiwAc91wfYOE1g1djOEDseZJKKqtHAHGwnGPQu3kytmfaXLQ==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-arm-musleabihf": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.54.0.tgz",
            "integrity": "sha512-+pBrqEjaakN2ySv5RVrj/qLytYhPKEUwk+e3SFU5jTLHIcAtqh2rLrd/OkbNuHJpsBgxsD8ccJt5ga/SeG0JmA==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-arm64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.54.0.tgz",
            "integrity": "sha512-NSqc7rE9wuUaRBsBp5ckQ5CVz5aIRKCwsoa6WMF7G01sX3/qHUw/z4pv+D+ahL1EIKy6Enpcnz1RY8pf7bjwng==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-arm64-musl": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.54.0.tgz",
            "integrity": "sha512-gr5vDbg3Bakga5kbdpqx81m2n9IX8M6gIMlQQIXiLTNeQW6CucvuInJ91EuCJ/JYvc+rcLLsDFcfAD1K7fMofg==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-loong64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.54.0.tgz",
            "integrity": "sha512-gsrtB1NA3ZYj2vq0Rzkylo9ylCtW/PhpLEivlgWe0bpgtX5+9j9EZa0wtZiCjgu6zmSeZWyI/e2YRX1URozpIw==",
            "cpu": [
                "loong64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-ppc64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.54.0.tgz",
            "integrity": "sha512-y3qNOfTBStmFNq+t4s7Tmc9hW2ENtPg8FeUD/VShI7rKxNW7O4fFeaYbMsd3tpFlIg1Q8IapFgy7Q9i2BqeBvA==",
            "cpu": [
                "ppc64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-riscv64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.54.0.tgz",
            "integrity": "sha512-89sepv7h2lIVPsFma8iwmccN7Yjjtgz0Rj/Ou6fEqg3HDhpCa+Et+YSufy27i6b0Wav69Qv4WBNl3Rs6pwhebQ==",
            "cpu": [
                "riscv64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-riscv64-musl": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.54.0.tgz",
            "integrity": "sha512-ZcU77ieh0M2Q8Ur7D5X7KvK+UxbXeDHwiOt/CPSBTI1fBmeDMivW0dPkdqkT4rOgDjrDDBUed9x4EgraIKoR2A==",
            "cpu": [
                "riscv64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-s390x-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.54.0.tgz",
            "integrity": "sha512-2AdWy5RdDF5+4YfG/YesGDDtbyJlC9LHmL6rZw6FurBJ5n4vFGupsOBGfwMRjBYH7qRQowT8D/U4LoSvVwOhSQ==",
            "cpu": [
                "s390x"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-x64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.54.0.tgz",
            "integrity": "sha512-WGt5J8Ij/rvyqpFexxk3ffKqqbLf9AqrTBbWDk7ApGUzaIs6V+s2s84kAxklFwmMF/vBNGrVdYgbblCOFFezMQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-linux-x64-musl": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.54.0.tgz",
            "integrity": "sha512-JzQmb38ATzHjxlPHuTH6tE7ojnMKM2kYNzt44LO/jJi8BpceEC8QuXYA908n8r3CNuG/B3BV8VR3Hi1rYtmPiw==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ]
        },
        "node_modules/@rollup/rollup-openharmony-arm64": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.54.0.tgz",
            "integrity": "sha512-huT3fd0iC7jigGh7n3q/+lfPcXxBi+om/Rs3yiFxjvSxbSB6aohDFXbWvlspaqjeOh+hx7DDHS+5Es5qRkWkZg==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "openharmony"
            ]
        },
        "node_modules/@rollup/rollup-win32-arm64-msvc": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.54.0.tgz",
            "integrity": "sha512-c2V0W1bsKIKfbLMBu/WGBz6Yci8nJ/ZJdheE0EwB73N3MvHYKiKGs3mVilX4Gs70eGeDaMqEob25Tw2Gb9Nqyw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ]
        },
        "node_modules/@rollup/rollup-win32-ia32-msvc": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.54.0.tgz",
            "integrity": "sha512-woEHgqQqDCkAzrDhvDipnSirm5vxUXtSKDYTVpZG3nUdW/VVB5VdCYA2iReSj/u3yCZzXID4kuKG7OynPnB3WQ==",
            "cpu": [
                "ia32"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ]
        },
        "node_modules/@rollup/rollup-win32-x64-gnu": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.54.0.tgz",
            "integrity": "sha512-dzAc53LOuFvHwbCEOS0rPbXp6SIhAf2txMP5p6mGyOXXw5mWY8NGGbPMPrs4P1WItkfApDathBj/NzMLUZ9rtQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ]
        },
        "node_modules/@rollup/rollup-win32-x64-msvc": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.54.0.tgz",
            "integrity": "sha512-hYT5d3YNdSh3mbCU1gwQyPgQd3T2ne0A3KG8KSBdav5TiBg6eInVmV+TeR5uHufiIgSFg0XsOWGW5/RhNcSvPg==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ]
        },
        "node_modules/@tailwindcss/forms": {
            "version": "0.5.11",
            "resolved": "https://registry.npmjs.org/@tailwindcss/forms/-/forms-0.5.11.tgz",
            "integrity": "sha512-h9wegbZDPurxG22xZSoWtdzc41/OlNEUQERNqI/0fOwa2aVlWGu7C35E/x6LDyD3lgtztFSSjKZyuVM0hxhbgA==",
            "dev": true,
            "dependencies": {
                "mini-svg-data-uri": "^1.2.3"
            },
            "peerDependencies": {
                "tailwindcss": ">=3.0.0 || >= 3.0.0-alpha.1 || >= 4.0.0-alpha.20 || >= 4.0.0-beta.1"
            }
        },
        "node_modules/@tailwindcss/node": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/node/-/node-4.1.18.tgz",
            "integrity": "sha512-DoR7U1P7iYhw16qJ49fgXUlry1t4CpXeErJHnQ44JgTSKMaZUdf17cfn5mHchfJ4KRBZRFA/Coo+MUF5+gOaCQ==",
            "dev": true,
            "dependencies": {
                "@jridgewell/remapping": "^2.3.4",
                "enhanced-resolve": "^5.18.3",
                "jiti": "^2.6.1",
                "lightningcss": "1.30.2",
                "magic-string": "^0.30.21",
                "source-map-js": "^1.2.1",
                "tailwindcss": "4.1.18"
            }
        },
        "node_modules/@tailwindcss/node/node_modules/tailwindcss": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.1.18.tgz",
            "integrity": "sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw==",
            "dev": true
        },
        "node_modules/@tailwindcss/oxide": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide/-/oxide-4.1.18.tgz",
            "integrity": "sha512-EgCR5tTS5bUSKQgzeMClT6iCY3ToqE1y+ZB0AKldj809QXk1Y+3jB0upOYZrn9aGIzPtUsP7sX4QQ4XtjBB95A==",
            "dev": true,
            "engines": {
                "node": ">= 10"
            },
            "optionalDependencies": {
                "@tailwindcss/oxide-android-arm64": "4.1.18",
                "@tailwindcss/oxide-darwin-arm64": "4.1.18",
                "@tailwindcss/oxide-darwin-x64": "4.1.18",
                "@tailwindcss/oxide-freebsd-x64": "4.1.18",
                "@tailwindcss/oxide-linux-arm-gnueabihf": "4.1.18",
                "@tailwindcss/oxide-linux-arm64-gnu": "4.1.18",
                "@tailwindcss/oxide-linux-arm64-musl": "4.1.18",
                "@tailwindcss/oxide-linux-x64-gnu": "4.1.18",
                "@tailwindcss/oxide-linux-x64-musl": "4.1.18",
                "@tailwindcss/oxide-wasm32-wasi": "4.1.18",
                "@tailwindcss/oxide-win32-arm64-msvc": "4.1.18",
                "@tailwindcss/oxide-win32-x64-msvc": "4.1.18"
            }
        },
        "node_modules/@tailwindcss/oxide-android-arm64": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-android-arm64/-/oxide-android-arm64-4.1.18.tgz",
            "integrity": "sha512-dJHz7+Ugr9U/diKJA0W6N/6/cjI+ZTAoxPf9Iz9BFRF2GzEX8IvXxFIi/dZBloVJX/MZGvRuFA9rqwdiIEZQ0Q==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-darwin-arm64": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-arm64/-/oxide-darwin-arm64-4.1.18.tgz",
            "integrity": "sha512-Gc2q4Qhs660bhjyBSKgq6BYvwDz4G+BuyJ5H1xfhmDR3D8HnHCmT/BSkvSL0vQLy/nkMLY20PQ2OoYMO15Jd0A==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-darwin-x64": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-darwin-x64/-/oxide-darwin-x64-4.1.18.tgz",
            "integrity": "sha512-FL5oxr2xQsFrc3X9o1fjHKBYBMD1QZNyc1Xzw/h5Qu4XnEBi3dZn96HcHm41c/euGV+GRiXFfh2hUCyKi/e+yw==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-freebsd-x64": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-freebsd-x64/-/oxide-freebsd-x64-4.1.18.tgz",
            "integrity": "sha512-Fj+RHgu5bDodmV1dM9yAxlfJwkkWvLiRjbhuO2LEtwtlYlBgiAT4x/j5wQr1tC3SANAgD+0YcmWVrj8R9trVMA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-linux-arm-gnueabihf": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm-gnueabihf/-/oxide-linux-arm-gnueabihf-4.1.18.tgz",
            "integrity": "sha512-Fp+Wzk/Ws4dZn+LV2Nqx3IilnhH51YZoRaYHQsVq3RQvEl+71VGKFpkfHrLM/Li+kt5c0DJe/bHXK1eHgDmdiA==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-linux-arm64-gnu": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-gnu/-/oxide-linux-arm64-gnu-4.1.18.tgz",
            "integrity": "sha512-S0n3jboLysNbh55Vrt7pk9wgpyTTPD0fdQeh7wQfMqLPM/Hrxi+dVsLsPrycQjGKEQk85Kgbx+6+QnYNiHalnw==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-linux-arm64-musl": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-arm64-musl/-/oxide-linux-arm64-musl-4.1.18.tgz",
            "integrity": "sha512-1px92582HkPQlaaCkdRcio71p8bc8i/ap5807tPRDK/uw953cauQBT8c5tVGkOwrHMfc2Yh6UuxaH4vtTjGvHg==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-linux-x64-gnu": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-gnu/-/oxide-linux-x64-gnu-4.1.18.tgz",
            "integrity": "sha512-v3gyT0ivkfBLoZGF9LyHmts0Isc8jHZyVcbzio6Wpzifg/+5ZJpDiRiUhDLkcr7f/r38SWNe7ucxmGW3j3Kb/g==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-linux-x64-musl": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-linux-x64-musl/-/oxide-linux-x64-musl-4.1.18.tgz",
            "integrity": "sha512-bhJ2y2OQNlcRwwgOAGMY0xTFStt4/wyU6pvI6LSuZpRgKQwxTec0/3Scu91O8ir7qCR3AuepQKLU/kX99FouqQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-wasm32-wasi": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-wasm32-wasi/-/oxide-wasm32-wasi-4.1.18.tgz",
            "integrity": "sha512-LffYTvPjODiP6PT16oNeUQJzNVyJl1cjIebq/rWWBF+3eDst5JGEFSc5cWxyRCJ0Mxl+KyIkqRxk1XPEs9x8TA==",
            "bundleDependencies": [
                "@napi-rs/wasm-runtime",
                "@emnapi/core",
                "@emnapi/runtime",
                "@tybys/wasm-util",
                "@emnapi/wasi-threads",
                "tslib"
            ],
            "cpu": [
                "wasm32"
            ],
            "dev": true,
            "optional": true,
            "dependencies": {
                "@emnapi/core": "^1.7.1",
                "@emnapi/runtime": "^1.7.1",
                "@emnapi/wasi-threads": "^1.1.0",
                "@napi-rs/wasm-runtime": "^1.1.0",
                "@tybys/wasm-util": "^0.10.1",
                "tslib": "^2.4.0"
            },
            "engines": {
                "node": ">=14.0.0"
            }
        },
        "node_modules/@tailwindcss/oxide-win32-arm64-msvc": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-arm64-msvc/-/oxide-win32-arm64-msvc-4.1.18.tgz",
            "integrity": "sha512-HjSA7mr9HmC8fu6bdsZvZ+dhjyGCLdotjVOgLA2vEqxEBZaQo9YTX4kwgEvPCpRh8o4uWc4J/wEoFzhEmjvPbA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/oxide-win32-x64-msvc": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/oxide-win32-x64-msvc/-/oxide-win32-x64-msvc-4.1.18.tgz",
            "integrity": "sha512-bJWbyYpUlqamC8dpR7pfjA0I7vdF6t5VpUGMWRkXVE3AXgIZjYUYAK7II1GNaxR8J1SSrSrppRar8G++JekE3Q==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">= 10"
            }
        },
        "node_modules/@tailwindcss/vite": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.1.18.tgz",
            "integrity": "sha512-jVA+/UpKL1vRLg6Hkao5jldawNmRo7mQYrZtNHMIVpLfLhDml5nMRUo/8MwoX2vNXvnaXNNMedrMfMugAVX1nA==",
            "dev": true,
            "dependencies": {
                "@tailwindcss/node": "4.1.18",
                "@tailwindcss/oxide": "4.1.18",
                "tailwindcss": "4.1.18"
            },
            "peerDependencies": {
                "vite": "^5.2.0 || ^6 || ^7"
            }
        },
        "node_modules/@tailwindcss/vite/node_modules/tailwindcss": {
            "version": "4.1.18",
            "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.1.18.tgz",
            "integrity": "sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw==",
            "dev": true
        },
        "node_modules/@types/estree": {
            "version": "1.0.8",
            "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
            "integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==",
            "dev": true
        },
        "node_modules/@vue/reactivity": {
            "version": "3.1.5",
            "resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.1.5.tgz",
            "integrity": "sha512-1tdfLmNjWG6t/CsPldh+foumYFo3cpyCHgBYQ34ylaMsJ+SNHQ1kApMIa8jN+i593zQuaw3AdWH0nJTARzCFhg==",
            "dev": true,
            "dependencies": {
                "@vue/shared": "3.1.5"
            }
        },
        "node_modules/@vue/shared": {
            "version": "3.1.5",
            "resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.1.5.tgz",
            "integrity": "sha512-oJ4F3TnvpXaQwZJNF3ZK+kLPHKarDmJjJ6jyzVNDKH9md1dptjC7lWR//jrGuLdek/U6iltWxqAnYOu8gCiOvA==",
            "dev": true
        },
        "node_modules/alpinejs": {
            "version": "3.15.3",
            "resolved": "https://registry.npmjs.org/alpinejs/-/alpinejs-3.15.3.tgz",
            "integrity": "sha512-fSI6F5213FdpMC4IWaup92KhuH3jBX0VVqajRJ6cOTCy1cL6888KyXdGO+seAAkn+g6fnrxBqQEx6gRpQ5EZoQ==",
            "dev": true,
            "dependencies": {
                "@vue/reactivity": "~3.1.1"
            }
        },
        "node_modules/ansi-regex": {
            "version": "5.0.1",
            "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz",
            "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==",
            "dev": true,
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/ansi-styles": {
            "version": "4.3.0",
            "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
            "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
            "dev": true,
            "dependencies": {
                "color-convert": "^2.0.1"
            },
            "engines": {
                "node": ">=8"
            },
            "funding": {
                "url": "https://github.com/chalk/ansi-styles?sponsor=1"
            }
        },
        "node_modules/any-promise": {
            "version": "1.3.0",
            "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz",
            "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==",
            "dev": true
        },
        "node_modules/anymatch": {
            "version": "3.1.3",
            "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz",
            "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==",
            "dev": true,
            "dependencies": {
                "normalize-path": "^3.0.0",
                "picomatch": "^2.0.4"
            },
            "engines": {
                "node": ">= 8"
            }
        },
        "node_modules/arg": {
            "version": "5.0.2",
            "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz",
            "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==",
            "dev": true
        },
        "node_modules/asynckit": {
            "version": "0.4.0",
            "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
            "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==",
            "dev": true
        },
        "node_modules/autoprefixer": {
            "version": "10.4.23",
            "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.23.tgz",
            "integrity": "sha512-YYTXSFulfwytnjAPlw8QHncHJmlvFKtczb8InXaAx9Q0LbfDnfEYDE55omerIJKihhmU61Ft+cAOSzQVaBUmeA==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/postcss/"
                },
                {
                    "type": "tidelift",
                    "url": "https://tidelift.com/funding/github/npm/autoprefixer"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "browserslist": "^4.28.1",
                "caniuse-lite": "^1.0.30001760",
                "fraction.js": "^5.3.4",
                "picocolors": "^1.1.1",
                "postcss-value-parser": "^4.2.0"
            },
            "bin": {
                "autoprefixer": "bin/autoprefixer"
            },
            "engines": {
                "node": "^10 || ^12 || >=14"
            },
            "peerDependencies": {
                "postcss": "^8.1.0"
            }
        },
        "node_modules/axios": {
            "version": "1.13.2",
            "resolved": "https://registry.npmjs.org/axios/-/axios-1.13.2.tgz",
            "integrity": "sha512-VPk9ebNqPcy5lRGuSlKx752IlDatOjT9paPlm8A7yOuW2Fbvp4X3JznJtT4f0GzGLLiWE9W8onz51SqLYwzGaA==",
            "dev": true,
            "dependencies": {
                "follow-redirects": "^1.15.6",
                "form-data": "^4.0.4",
                "proxy-from-env": "^1.1.0"
            }
        },
        "node_modules/baseline-browser-mapping": {
            "version": "2.9.11",
            "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.11.tgz",
            "integrity": "sha512-Sg0xJUNDU1sJNGdfGWhVHX0kkZ+HWcvmVymJbj6NSgZZmW/8S9Y2HQ5euytnIgakgxN6papOAWiwDo1ctFDcoQ==",
            "dev": true,
            "bin": {
                "baseline-browser-mapping": "dist/cli.js"
            }
        },
        "node_modules/binary-extensions": {
            "version": "2.3.0",
            "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.3.0.tgz",
            "integrity": "sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==",
            "dev": true,
            "engines": {
                "node": ">=8"
            },
            "funding": {
                "url": "https://github.com/sponsors/sindresorhus"
            }
        },
        "node_modules/braces": {
            "version": "3.0.3",
            "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz",
            "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==",
            "dev": true,
            "dependencies": {
                "fill-range": "^7.1.1"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/browserslist": {
            "version": "4.28.1",
            "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.1.tgz",
            "integrity": "sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/browserslist"
                },
                {
                    "type": "tidelift",
                    "url": "https://tidelift.com/funding/github/npm/browserslist"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "baseline-browser-mapping": "^2.9.0",
                "caniuse-lite": "^1.0.30001759",
                "electron-to-chromium": "^1.5.263",
                "node-releases": "^2.0.27",
                "update-browserslist-db": "^1.2.0"
            },
            "bin": {
                "browserslist": "cli.js"
            },
            "engines": {
                "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7"
            }
        },
        "node_modules/call-bind-apply-helpers": {
            "version": "1.0.2",
            "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz",
            "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==",
            "dev": true,
            "dependencies": {
                "es-errors": "^1.3.0",
                "function-bind": "^1.1.2"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/camelcase-css": {
            "version": "2.0.1",
            "resolved": "https://registry.npmjs.org/camelcase-css/-/camelcase-css-2.0.1.tgz",
            "integrity": "sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==",
            "dev": true,
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/caniuse-lite": {
            "version": "1.0.30001762",
            "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001762.tgz",
            "integrity": "sha512-PxZwGNvH7Ak8WX5iXzoK1KPZttBXNPuaOvI2ZYU7NrlM+d9Ov+TUvlLOBNGzVXAntMSMMlJPd+jY6ovrVjSmUw==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/browserslist"
                },
                {
                    "type": "tidelift",
                    "url": "https://tidelift.com/funding/github/npm/caniuse-lite"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ]
        },
        "node_modules/chalk": {
            "version": "4.1.2",
            "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
            "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
            "dev": true,
            "dependencies": {
                "ansi-styles": "^4.1.0",
                "supports-color": "^7.1.0"
            },
            "engines": {
                "node": ">=10"
            },
            "funding": {
                "url": "https://github.com/chalk/chalk?sponsor=1"
            }
        },
        "node_modules/chalk/node_modules/supports-color": {
            "version": "7.2.0",
            "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
            "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
            "dev": true,
            "dependencies": {
                "has-flag": "^4.0.0"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/chokidar": {
            "version": "3.6.0",
            "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz",
            "integrity": "sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==",
            "dev": true,
            "dependencies": {
                "anymatch": "~3.1.2",
                "braces": "~3.0.2",
                "glob-parent": "~5.1.2",
                "is-binary-path": "~2.1.0",
                "is-glob": "~4.0.1",
                "normalize-path": "~3.0.0",
                "readdirp": "~3.6.0"
            },
            "engines": {
                "node": ">= 8.10.0"
            },
            "funding": {
                "url": "https://paulmillr.com/funding/"
            },
            "optionalDependencies": {
                "fsevents": "~2.3.2"
            }
        },
        "node_modules/chokidar/node_modules/glob-parent": {
            "version": "5.1.2",
            "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
            "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
            "dev": true,
            "dependencies": {
                "is-glob": "^4.0.1"
            },
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/cliui": {
            "version": "8.0.1",
            "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz",
            "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==",
            "dev": true,
            "dependencies": {
                "string-width": "^4.2.0",
                "strip-ansi": "^6.0.1",
                "wrap-ansi": "^7.0.0"
            },
            "engines": {
                "node": ">=12"
            }
        },
        "node_modules/color-convert": {
            "version": "2.0.1",
            "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
            "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
            "dev": true,
            "dependencies": {
                "color-name": "~1.1.4"
            },
            "engines": {
                "node": ">=7.0.0"
            }
        },
        "node_modules/color-name": {
            "version": "1.1.4",
            "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
            "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
            "dev": true
        },
        "node_modules/combined-stream": {
            "version": "1.0.8",
            "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
            "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
            "dev": true,
            "dependencies": {
                "delayed-stream": "~1.0.0"
            },
            "engines": {
                "node": ">= 0.8"
            }
        },
        "node_modules/commander": {
            "version": "4.1.1",
            "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz",
            "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==",
            "dev": true,
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/concurrently": {
            "version": "9.2.1",
            "resolved": "https://registry.npmjs.org/concurrently/-/concurrently-9.2.1.tgz",
            "integrity": "sha512-fsfrO0MxV64Znoy8/l1vVIjjHa29SZyyqPgQBwhiDcaW8wJc2W3XWVOGx4M3oJBnv/zdUZIIp1gDeS98GzP8Ng==",
            "dev": true,
            "dependencies": {
                "chalk": "4.1.2",
                "rxjs": "7.8.2",
                "shell-quote": "1.8.3",
                "supports-color": "8.1.1",
                "tree-kill": "1.2.2",
                "yargs": "17.7.2"
            },
            "bin": {
                "conc": "dist/bin/concurrently.js",
                "concurrently": "dist/bin/concurrently.js"
            },
            "engines": {
                "node": ">=18"
            },
            "funding": {
                "url": "https://github.com/open-cli-tools/concurrently?sponsor=1"
            }
        },
        "node_modules/cssesc": {
            "version": "3.0.0",
            "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz",
            "integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==",
            "dev": true,
            "bin": {
                "cssesc": "bin/cssesc"
            },
            "engines": {
                "node": ">=4"
            }
        },
        "node_modules/delayed-stream": {
            "version": "1.0.0",
            "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
            "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==",
            "dev": true,
            "engines": {
                "node": ">=0.4.0"
            }
        },
        "node_modules/detect-libc": {
            "version": "2.1.2",
            "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz",
            "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==",
            "dev": true,
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/didyoumean": {
            "version": "1.2.2",
            "resolved": "https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz",
            "integrity": "sha512-gxtyfqMg7GKyhQmb056K7M3xszy/myH8w+B4RT+QXBQsvAOdc3XymqDDPHx1BgPgsdAA5SIifona89YtRATDzw==",
            "dev": true
        },
        "node_modules/dlv": {
            "version": "1.1.3",
            "resolved": "https://registry.npmjs.org/dlv/-/dlv-1.1.3.tgz",
            "integrity": "sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==",
            "dev": true
        },
        "node_modules/dunder-proto": {
            "version": "1.0.1",
            "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz",
            "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==",
            "dev": true,
            "dependencies": {
                "call-bind-apply-helpers": "^1.0.1",
                "es-errors": "^1.3.0",
                "gopd": "^1.2.0"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/electron-to-chromium": {
            "version": "1.5.267",
            "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.267.tgz",
            "integrity": "sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==",
            "dev": true
        },
        "node_modules/emoji-regex": {
            "version": "8.0.0",
            "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
            "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==",
            "dev": true
        },
        "node_modules/enhanced-resolve": {
            "version": "5.18.4",
            "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.18.4.tgz",
            "integrity": "sha512-LgQMM4WXU3QI+SYgEc2liRgznaD5ojbmY3sb8LxyguVkIg5FxdpTkvk72te2R38/TGKxH634oLxXRGY6d7AP+Q==",
            "dev": true,
            "dependencies": {
                "graceful-fs": "^4.2.4",
                "tapable": "^2.2.0"
            },
            "engines": {
                "node": ">=10.13.0"
            }
        },
        "node_modules/es-define-property": {
            "version": "1.0.1",
            "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz",
            "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/es-errors": {
            "version": "1.3.0",
            "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz",
            "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/es-object-atoms": {
            "version": "1.1.1",
            "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz",
            "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==",
            "dev": true,
            "dependencies": {
                "es-errors": "^1.3.0"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/es-set-tostringtag": {
            "version": "2.1.0",
            "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz",
            "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==",
            "dev": true,
            "dependencies": {
                "es-errors": "^1.3.0",
                "get-intrinsic": "^1.2.6",
                "has-tostringtag": "^1.0.2",
                "hasown": "^2.0.2"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/esbuild": {
            "version": "0.27.2",
            "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.27.2.tgz",
            "integrity": "sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==",
            "dev": true,
            "hasInstallScript": true,
            "bin": {
                "esbuild": "bin/esbuild"
            },
            "engines": {
                "node": ">=18"
            },
            "optionalDependencies": {
                "@esbuild/aix-ppc64": "0.27.2",
                "@esbuild/android-arm": "0.27.2",
                "@esbuild/android-arm64": "0.27.2",
                "@esbuild/android-x64": "0.27.2",
                "@esbuild/darwin-arm64": "0.27.2",
                "@esbuild/darwin-x64": "0.27.2",
                "@esbuild/freebsd-arm64": "0.27.2",
                "@esbuild/freebsd-x64": "0.27.2",
                "@esbuild/linux-arm": "0.27.2",
                "@esbuild/linux-arm64": "0.27.2",
                "@esbuild/linux-ia32": "0.27.2",
                "@esbuild/linux-loong64": "0.27.2",
                "@esbuild/linux-mips64el": "0.27.2",
                "@esbuild/linux-ppc64": "0.27.2",
                "@esbuild/linux-riscv64": "0.27.2",
                "@esbuild/linux-s390x": "0.27.2",
                "@esbuild/linux-x64": "0.27.2",
                "@esbuild/netbsd-arm64": "0.27.2",
                "@esbuild/netbsd-x64": "0.27.2",
                "@esbuild/openbsd-arm64": "0.27.2",
                "@esbuild/openbsd-x64": "0.27.2",
                "@esbuild/openharmony-arm64": "0.27.2",
                "@esbuild/sunos-x64": "0.27.2",
                "@esbuild/win32-arm64": "0.27.2",
                "@esbuild/win32-ia32": "0.27.2",
                "@esbuild/win32-x64": "0.27.2"
            }
        },
        "node_modules/escalade": {
            "version": "3.2.0",
            "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz",
            "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==",
            "dev": true,
            "engines": {
                "node": ">=6"
            }
        },
        "node_modules/fast-glob": {
            "version": "3.3.3",
            "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz",
            "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==",
            "dev": true,
            "dependencies": {
                "@nodelib/fs.stat": "^2.0.2",
                "@nodelib/fs.walk": "^1.2.3",
                "glob-parent": "^5.1.2",
                "merge2": "^1.3.0",
                "micromatch": "^4.0.8"
            },
            "engines": {
                "node": ">=8.6.0"
            }
        },
        "node_modules/fast-glob/node_modules/glob-parent": {
            "version": "5.1.2",
            "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
            "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
            "dev": true,
            "dependencies": {
                "is-glob": "^4.0.1"
            },
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/fastq": {
            "version": "1.20.1",
            "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.1.tgz",
            "integrity": "sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw==",
            "dev": true,
            "dependencies": {
                "reusify": "^1.0.4"
            }
        },
        "node_modules/fill-range": {
            "version": "7.1.1",
            "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz",
            "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==",
            "dev": true,
            "dependencies": {
                "to-regex-range": "^5.0.1"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/follow-redirects": {
            "version": "1.15.11",
            "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.11.tgz",
            "integrity": "sha512-deG2P0JfjrTxl50XGCDyfI97ZGVCxIpfKYmfyrQ54n5FO/0gfIES8C/Psl6kWVDolizcaaxZJnTS0QSMxvnsBQ==",
            "dev": true,
            "funding": [
                {
                    "type": "individual",
                    "url": "https://github.com/sponsors/RubenVerborgh"
                }
            ],
            "engines": {
                "node": ">=4.0"
            },
            "peerDependenciesMeta": {
                "debug": {
                    "optional": true
                }
            }
        },
        "node_modules/form-data": {
            "version": "4.0.5",
            "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.5.tgz",
            "integrity": "sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w==",
            "dev": true,
            "dependencies": {
                "asynckit": "^0.4.0",
                "combined-stream": "^1.0.8",
                "es-set-tostringtag": "^2.1.0",
                "hasown": "^2.0.2",
                "mime-types": "^2.1.12"
            },
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/fraction.js": {
            "version": "5.3.4",
            "resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-5.3.4.tgz",
            "integrity": "sha512-1X1NTtiJphryn/uLQz3whtY6jK3fTqoE3ohKs0tT+Ujr1W59oopxmoEh7Lu5p6vBaPbgoM0bzveAW4Qi5RyWDQ==",
            "dev": true,
            "engines": {
                "node": "*"
            },
            "funding": {
                "type": "github",
                "url": "https://github.com/sponsors/rawify"
            }
        },
        "node_modules/fsevents": {
            "version": "2.3.3",
            "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
            "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
            "dev": true,
            "hasInstallScript": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": "^8.16.0 || ^10.6.0 || >=11.0.0"
            }
        },
        "node_modules/function-bind": {
            "version": "1.1.2",
            "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz",
            "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==",
            "dev": true,
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/get-caller-file": {
            "version": "2.0.5",
            "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
            "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==",
            "dev": true,
            "engines": {
                "node": "6.* || 8.* || >= 10.*"
            }
        },
        "node_modules/get-intrinsic": {
            "version": "1.3.0",
            "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz",
            "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==",
            "dev": true,
            "dependencies": {
                "call-bind-apply-helpers": "^1.0.2",
                "es-define-property": "^1.0.1",
                "es-errors": "^1.3.0",
                "es-object-atoms": "^1.1.1",
                "function-bind": "^1.1.2",
                "get-proto": "^1.0.1",
                "gopd": "^1.2.0",
                "has-symbols": "^1.1.0",
                "hasown": "^2.0.2",
                "math-intrinsics": "^1.1.0"
            },
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/get-proto": {
            "version": "1.0.1",
            "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz",
            "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==",
            "dev": true,
            "dependencies": {
                "dunder-proto": "^1.0.1",
                "es-object-atoms": "^1.0.0"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/glob-parent": {
            "version": "6.0.2",
            "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
            "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
            "dev": true,
            "dependencies": {
                "is-glob": "^4.0.3"
            },
            "engines": {
                "node": ">=10.13.0"
            }
        },
        "node_modules/gopd": {
            "version": "1.2.0",
            "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz",
            "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/graceful-fs": {
            "version": "4.2.11",
            "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
            "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
            "dev": true
        },
        "node_modules/has-flag": {
            "version": "4.0.0",
            "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
            "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
            "dev": true,
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/has-symbols": {
            "version": "1.1.0",
            "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz",
            "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/has-tostringtag": {
            "version": "1.0.2",
            "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz",
            "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==",
            "dev": true,
            "dependencies": {
                "has-symbols": "^1.0.3"
            },
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/hasown": {
            "version": "2.0.2",
            "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz",
            "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==",
            "dev": true,
            "dependencies": {
                "function-bind": "^1.1.2"
            },
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/is-binary-path": {
            "version": "2.1.0",
            "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz",
            "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==",
            "dev": true,
            "dependencies": {
                "binary-extensions": "^2.0.0"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/is-core-module": {
            "version": "2.16.1",
            "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.16.1.tgz",
            "integrity": "sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==",
            "dev": true,
            "dependencies": {
                "hasown": "^2.0.2"
            },
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/is-extglob": {
            "version": "2.1.1",
            "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
            "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/is-fullwidth-code-point": {
            "version": "3.0.0",
            "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
            "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
            "dev": true,
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/is-glob": {
            "version": "4.0.3",
            "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
            "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
            "dev": true,
            "dependencies": {
                "is-extglob": "^2.1.1"
            },
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/is-number": {
            "version": "7.0.0",
            "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
            "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==",
            "dev": true,
            "engines": {
                "node": ">=0.12.0"
            }
        },
        "node_modules/jiti": {
            "version": "2.6.1",
            "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.6.1.tgz",
            "integrity": "sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==",
            "dev": true,
            "bin": {
                "jiti": "lib/jiti-cli.mjs"
            }
        },
        "node_modules/laravel-vite-plugin": {
            "version": "2.0.1",
            "resolved": "https://registry.npmjs.org/laravel-vite-plugin/-/laravel-vite-plugin-2.0.1.tgz",
            "integrity": "sha512-zQuvzWfUKQu9oNVi1o0RZAJCwhGsdhx4NEOyrVQwJHaWDseGP9tl7XUPLY2T8Cj6+IrZ6lmyxlR1KC8unf3RLA==",
            "dev": true,
            "dependencies": {
                "picocolors": "^1.0.0",
                "vite-plugin-full-reload": "^1.1.0"
            },
            "bin": {
                "clean-orphaned-assets": "bin/clean.js"
            },
            "engines": {
                "node": "^20.19.0 || >=22.12.0"
            },
            "peerDependencies": {
                "vite": "^7.0.0"
            }
        },
        "node_modules/lightningcss": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.30.2.tgz",
            "integrity": "sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ==",
            "dev": true,
            "dependencies": {
                "detect-libc": "^2.0.3"
            },
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            },
            "optionalDependencies": {
                "lightningcss-android-arm64": "1.30.2",
                "lightningcss-darwin-arm64": "1.30.2",
                "lightningcss-darwin-x64": "1.30.2",
                "lightningcss-freebsd-x64": "1.30.2",
                "lightningcss-linux-arm-gnueabihf": "1.30.2",
                "lightningcss-linux-arm64-gnu": "1.30.2",
                "lightningcss-linux-arm64-musl": "1.30.2",
                "lightningcss-linux-x64-gnu": "1.30.2",
                "lightningcss-linux-x64-musl": "1.30.2",
                "lightningcss-win32-arm64-msvc": "1.30.2",
                "lightningcss-win32-x64-msvc": "1.30.2"
            }
        },
        "node_modules/lightningcss-android-arm64": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-android-arm64/-/lightningcss-android-arm64-1.30.2.tgz",
            "integrity": "sha512-BH9sEdOCahSgmkVhBLeU7Hc9DWeZ1Eb6wNS6Da8igvUwAe0sqROHddIlvU06q3WyXVEOYDZ6ykBZQnjTbmo4+A==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "android"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-darwin-arm64": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.30.2.tgz",
            "integrity": "sha512-ylTcDJBN3Hp21TdhRT5zBOIi73P6/W0qwvlFEk22fkdXchtNTOU4Qc37SkzV+EKYxLouZ6M4LG9NfZ1qkhhBWA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-darwin-x64": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.30.2.tgz",
            "integrity": "sha512-oBZgKchomuDYxr7ilwLcyms6BCyLn0z8J0+ZZmfpjwg9fRVZIR5/GMXd7r9RH94iDhld3UmSjBM6nXWM2TfZTQ==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "darwin"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-freebsd-x64": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.30.2.tgz",
            "integrity": "sha512-c2bH6xTrf4BDpK8MoGG4Bd6zAMZDAXS569UxCAGcA7IKbHNMlhGQ89eRmvpIUGfKWNVdbhSbkQaWhEoMGmGslA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "freebsd"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-linux-arm-gnueabihf": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.30.2.tgz",
            "integrity": "sha512-eVdpxh4wYcm0PofJIZVuYuLiqBIakQ9uFZmipf6LF/HRj5Bgm0eb3qL/mr1smyXIS1twwOxNWndd8z0E374hiA==",
            "cpu": [
                "arm"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-linux-arm64-gnu": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.30.2.tgz",
            "integrity": "sha512-UK65WJAbwIJbiBFXpxrbTNArtfuznvxAJw4Q2ZGlU8kPeDIWEX1dg3rn2veBVUylA2Ezg89ktszWbaQnxD/e3A==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-linux-arm64-musl": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.30.2.tgz",
            "integrity": "sha512-5Vh9dGeblpTxWHpOx8iauV02popZDsCYMPIgiuw97OJ5uaDsL86cnqSFs5LZkG3ghHoX5isLgWzMs+eD1YzrnA==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-linux-x64-gnu": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.30.2.tgz",
            "integrity": "sha512-Cfd46gdmj1vQ+lR6VRTTadNHu6ALuw2pKR9lYq4FnhvgBc4zWY1EtZcAc6EffShbb1MFrIPfLDXD6Xprbnni4w==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-linux-x64-musl": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.30.2.tgz",
            "integrity": "sha512-XJaLUUFXb6/QG2lGIW6aIk6jKdtjtcffUT0NKvIqhSBY3hh9Ch+1LCeH80dR9q9LBjG3ewbDjnumefsLsP6aiA==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "linux"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-win32-arm64-msvc": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.30.2.tgz",
            "integrity": "sha512-FZn+vaj7zLv//D/192WFFVA0RgHawIcHqLX9xuWiQt7P0PtdFEVaxgF9rjM/IRYHQXNnk61/H/gb2Ei+kUQ4xQ==",
            "cpu": [
                "arm64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lightningcss-win32-x64-msvc": {
            "version": "1.30.2",
            "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.30.2.tgz",
            "integrity": "sha512-5g1yc73p+iAkid5phb4oVFMB45417DkRevRbt/El/gKXJk4jid+vPFF/AXbxn05Aky8PapwzZrdJShv5C0avjw==",
            "cpu": [
                "x64"
            ],
            "dev": true,
            "optional": true,
            "os": [
                "win32"
            ],
            "engines": {
                "node": ">= 12.0.0"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/parcel"
            }
        },
        "node_modules/lilconfig": {
            "version": "3.1.3",
            "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-3.1.3.tgz",
            "integrity": "sha512-/vlFKAoH5Cgt3Ie+JLhRbwOsCQePABiU3tJ1egGvyQ+33R/vcwM2Zl2QR/LzjsBeItPt3oSVXapn+m4nQDvpzw==",
            "dev": true,
            "engines": {
                "node": ">=14"
            },
            "funding": {
                "url": "https://github.com/sponsors/antonk52"
            }
        },
        "node_modules/lines-and-columns": {
            "version": "1.2.4",
            "resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.2.4.tgz",
            "integrity": "sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==",
            "dev": true
        },
        "node_modules/magic-string": {
            "version": "0.30.21",
            "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz",
            "integrity": "sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==",
            "dev": true,
            "dependencies": {
                "@jridgewell/sourcemap-codec": "^1.5.5"
            }
        },
        "node_modules/math-intrinsics": {
            "version": "1.1.0",
            "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz",
            "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            }
        },
        "node_modules/merge2": {
            "version": "1.4.1",
            "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
            "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==",
            "dev": true,
            "engines": {
                "node": ">= 8"
            }
        },
        "node_modules/micromatch": {
            "version": "4.0.8",
            "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz",
            "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==",
            "dev": true,
            "dependencies": {
                "braces": "^3.0.3",
                "picomatch": "^2.3.1"
            },
            "engines": {
                "node": ">=8.6"
            }
        },
        "node_modules/mime-db": {
            "version": "1.52.0",
            "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz",
            "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==",
            "dev": true,
            "engines": {
                "node": ">= 0.6"
            }
        },
        "node_modules/mime-types": {
            "version": "2.1.35",
            "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz",
            "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==",
            "dev": true,
            "dependencies": {
                "mime-db": "1.52.0"
            },
            "engines": {
                "node": ">= 0.6"
            }
        },
        "node_modules/mini-svg-data-uri": {
            "version": "1.4.4",
            "resolved": "https://registry.npmjs.org/mini-svg-data-uri/-/mini-svg-data-uri-1.4.4.tgz",
            "integrity": "sha512-r9deDe9p5FJUPZAk3A59wGH7Ii9YrjjWw0jmw/liSbHl2CHiyXj6FcDXDu2K3TjVAXqiJdaw3xxwlZZr9E6nHg==",
            "dev": true,
            "bin": {
                "mini-svg-data-uri": "cli.js"
            }
        },
        "node_modules/mz": {
            "version": "2.7.0",
            "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz",
            "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==",
            "dev": true,
            "dependencies": {
                "any-promise": "^1.0.0",
                "object-assign": "^4.0.1",
                "thenify-all": "^1.0.0"
            }
        },
        "node_modules/nanoid": {
            "version": "3.3.11",
            "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz",
            "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==",
            "dev": true,
            "funding": [
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "bin": {
                "nanoid": "bin/nanoid.cjs"
            },
            "engines": {
                "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"
            }
        },
        "node_modules/node-releases": {
            "version": "2.0.27",
            "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz",
            "integrity": "sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==",
            "dev": true
        },
        "node_modules/normalize-path": {
            "version": "3.0.0",
            "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",
            "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/object-assign": {
            "version": "4.1.1",
            "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
            "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/object-hash": {
            "version": "3.0.0",
            "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-3.0.0.tgz",
            "integrity": "sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==",
            "dev": true,
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/path-parse": {
            "version": "1.0.7",
            "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz",
            "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==",
            "dev": true
        },
        "node_modules/picocolors": {
            "version": "1.1.1",
            "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz",
            "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
            "dev": true
        },
        "node_modules/picomatch": {
            "version": "2.3.1",
            "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz",
            "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==",
            "dev": true,
            "engines": {
                "node": ">=8.6"
            },
            "funding": {
                "url": "https://github.com/sponsors/jonschlinkert"
            }
        },
        "node_modules/pify": {
            "version": "2.3.0",
            "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
            "integrity": "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/pirates": {
            "version": "4.0.7",
            "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.7.tgz",
            "integrity": "sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA==",
            "dev": true,
            "engines": {
                "node": ">= 6"
            }
        },
        "node_modules/postcss": {
            "version": "8.5.6",
            "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.6.tgz",
            "integrity": "sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/postcss/"
                },
                {
                    "type": "tidelift",
                    "url": "https://tidelift.com/funding/github/npm/postcss"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "nanoid": "^3.3.11",
                "picocolors": "^1.1.1",
                "source-map-js": "^1.2.1"
            },
            "engines": {
                "node": "^10 || ^12 || >=14"
            }
        },
        "node_modules/postcss-import": {
            "version": "15.1.0",
            "resolved": "https://registry.npmjs.org/postcss-import/-/postcss-import-15.1.0.tgz",
            "integrity": "sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==",
            "dev": true,
            "dependencies": {
                "postcss-value-parser": "^4.0.0",
                "read-cache": "^1.0.0",
                "resolve": "^1.1.7"
            },
            "engines": {
                "node": ">=14.0.0"
            },
            "peerDependencies": {
                "postcss": "^8.0.0"
            }
        },
        "node_modules/postcss-js": {
            "version": "4.1.0",
            "resolved": "https://registry.npmjs.org/postcss-js/-/postcss-js-4.1.0.tgz",
            "integrity": "sha512-oIAOTqgIo7q2EOwbhb8UalYePMvYoIeRY2YKntdpFQXNosSu3vLrniGgmH9OKs/qAkfoj5oB3le/7mINW1LCfw==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/postcss/"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "camelcase-css": "^2.0.1"
            },
            "engines": {
                "node": "^12 || ^14 || >= 16"
            },
            "peerDependencies": {
                "postcss": "^8.4.21"
            }
        },
        "node_modules/postcss-load-config": {
            "version": "6.0.1",
            "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-6.0.1.tgz",
            "integrity": "sha512-oPtTM4oerL+UXmx+93ytZVN82RrlY/wPUV8IeDxFrzIjXOLF1pN+EmKPLbubvKHT2HC20xXsCAH2Z+CKV6Oz/g==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/postcss/"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "lilconfig": "^3.1.1"
            },
            "engines": {
                "node": ">= 18"
            },
            "peerDependencies": {
                "jiti": ">=1.21.0",
                "postcss": ">=8.0.9",
                "tsx": "^4.8.1",
                "yaml": "^2.4.2"
            },
            "peerDependenciesMeta": {
                "jiti": {
                    "optional": true
                },
                "postcss": {
                    "optional": true
                },
                "tsx": {
                    "optional": true
                },
                "yaml": {
                    "optional": true
                }
            }
        },
        "node_modules/postcss-nested": {
            "version": "6.2.0",
            "resolved": "https://registry.npmjs.org/postcss-nested/-/postcss-nested-6.2.0.tgz",
            "integrity": "sha512-HQbt28KulC5AJzG+cZtj9kvKB93CFCdLvog1WFLf1D+xmMvPGlBstkpTEZfK5+AN9hfJocyBFCNiqyS48bpgzQ==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/postcss/"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "postcss-selector-parser": "^6.1.1"
            },
            "engines": {
                "node": ">=12.0"
            },
            "peerDependencies": {
                "postcss": "^8.2.14"
            }
        },
        "node_modules/postcss-selector-parser": {
            "version": "6.1.2",
            "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.2.tgz",
            "integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==",
            "dev": true,
            "dependencies": {
                "cssesc": "^3.0.0",
                "util-deprecate": "^1.0.2"
            },
            "engines": {
                "node": ">=4"
            }
        },
        "node_modules/postcss-value-parser": {
            "version": "4.2.0",
            "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz",
            "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==",
            "dev": true
        },
        "node_modules/prettier": {
            "version": "3.8.1",
            "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.8.1.tgz",
            "integrity": "sha512-UOnG6LftzbdaHZcKoPFtOcCKztrQ57WkHDeRD9t/PTQtmT0NHSeWWepj6pS0z/N7+08BHFDQVUrfmfMRcZwbMg==",
            "dev": true,
            "license": "MIT",
            "peer": true,
            "bin": {
                "prettier": "bin/prettier.cjs"
            },
            "engines": {
                "node": ">=14"
            },
            "funding": {
                "url": "https://github.com/prettier/prettier?sponsor=1"
            }
        },
        "node_modules/prettier-plugin-blade": {
            "version": "2.1.21",
            "resolved": "https://registry.npmjs.org/prettier-plugin-blade/-/prettier-plugin-blade-2.1.21.tgz",
            "integrity": "sha512-+BPBPvla/Ppr0MVrqMAO+FTwxpXUYo8zhQPIGC7psNuMbB24y84cGrJ4Uc02GHTQN0q8txeG4Y4MxyJWgOujyQ==",
            "dev": true,
            "license": "MIT",
            "engines": {
                "node": ">=12.0.0"
            },
            "peerDependencies": {
                "prettier": ">=3"
            }
        },
        "node_modules/proxy-from-env": {
            "version": "1.1.0",
            "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz",
            "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==",
            "dev": true
        },
        "node_modules/queue-microtask": {
            "version": "1.2.3",
            "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
            "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
            "dev": true,
            "funding": [
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/feross"
                },
                {
                    "type": "patreon",
                    "url": "https://www.patreon.com/feross"
                },
                {
                    "type": "consulting",
                    "url": "https://feross.org/support"
                }
            ]
        },
        "node_modules/read-cache": {
            "version": "1.0.0",
            "resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz",
            "integrity": "sha512-Owdv/Ft7IjOgm/i0xvNDZ1LrRANRfew4b2prF3OWMQLxLfu3bS8FVhCsrSCMK4lR56Y9ya+AThoTpDCTxCmpRA==",
            "dev": true,
            "dependencies": {
                "pify": "^2.3.0"
            }
        },
        "node_modules/readdirp": {
            "version": "3.6.0",
            "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz",
            "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==",
            "dev": true,
            "dependencies": {
                "picomatch": "^2.2.1"
            },
            "engines": {
                "node": ">=8.10.0"
            }
        },
        "node_modules/require-directory": {
            "version": "2.1.1",
            "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
            "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/resolve": {
            "version": "1.22.11",
            "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz",
            "integrity": "sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==",
            "dev": true,
            "dependencies": {
                "is-core-module": "^2.16.1",
                "path-parse": "^1.0.7",
                "supports-preserve-symlinks-flag": "^1.0.0"
            },
            "bin": {
                "resolve": "bin/resolve"
            },
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/reusify": {
            "version": "1.1.0",
            "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz",
            "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==",
            "dev": true,
            "engines": {
                "iojs": ">=1.0.0",
                "node": ">=0.10.0"
            }
        },
        "node_modules/rollup": {
            "version": "4.54.0",
            "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.54.0.tgz",
            "integrity": "sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==",
            "dev": true,
            "dependencies": {
                "@types/estree": "1.0.8"
            },
            "bin": {
                "rollup": "dist/bin/rollup"
            },
            "engines": {
                "node": ">=18.0.0",
                "npm": ">=8.0.0"
            },
            "optionalDependencies": {
                "@rollup/rollup-android-arm-eabi": "4.54.0",
                "@rollup/rollup-android-arm64": "4.54.0",
                "@rollup/rollup-darwin-arm64": "4.54.0",
                "@rollup/rollup-darwin-x64": "4.54.0",
                "@rollup/rollup-freebsd-arm64": "4.54.0",
                "@rollup/rollup-freebsd-x64": "4.54.0",
                "@rollup/rollup-linux-arm-gnueabihf": "4.54.0",
                "@rollup/rollup-linux-arm-musleabihf": "4.54.0",
                "@rollup/rollup-linux-arm64-gnu": "4.54.0",
                "@rollup/rollup-linux-arm64-musl": "4.54.0",
                "@rollup/rollup-linux-loong64-gnu": "4.54.0",
                "@rollup/rollup-linux-ppc64-gnu": "4.54.0",
                "@rollup/rollup-linux-riscv64-gnu": "4.54.0",
                "@rollup/rollup-linux-riscv64-musl": "4.54.0",
                "@rollup/rollup-linux-s390x-gnu": "4.54.0",
                "@rollup/rollup-linux-x64-gnu": "4.54.0",
                "@rollup/rollup-linux-x64-musl": "4.54.0",
                "@rollup/rollup-openharmony-arm64": "4.54.0",
                "@rollup/rollup-win32-arm64-msvc": "4.54.0",
                "@rollup/rollup-win32-ia32-msvc": "4.54.0",
                "@rollup/rollup-win32-x64-gnu": "4.54.0",
                "@rollup/rollup-win32-x64-msvc": "4.54.0",
                "fsevents": "~2.3.2"
            }
        },
        "node_modules/run-parallel": {
            "version": "1.2.0",
            "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
            "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
            "dev": true,
            "funding": [
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/feross"
                },
                {
                    "type": "patreon",
                    "url": "https://www.patreon.com/feross"
                },
                {
                    "type": "consulting",
                    "url": "https://feross.org/support"
                }
            ],
            "dependencies": {
                "queue-microtask": "^1.2.2"
            }
        },
        "node_modules/rxjs": {
            "version": "7.8.2",
            "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.2.tgz",
            "integrity": "sha512-dhKf903U/PQZY6boNNtAGdWbG85WAbjT/1xYoZIC7FAY0yWapOBQVsVrDl58W86//e1VpMNBtRV4MaXfdMySFA==",
            "dev": true,
            "dependencies": {
                "tslib": "^2.1.0"
            }
        },
        "node_modules/shell-quote": {
            "version": "1.8.3",
            "resolved": "https://registry.npmjs.org/shell-quote/-/shell-quote-1.8.3.tgz",
            "integrity": "sha512-ObmnIF4hXNg1BqhnHmgbDETF8dLPCggZWBjkQfhZpbszZnYur5DUljTcCHii5LC3J5E0yeO/1LIMyH+UvHQgyw==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/source-map-js": {
            "version": "1.2.1",
            "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz",
            "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
            "dev": true,
            "engines": {
                "node": ">=0.10.0"
            }
        },
        "node_modules/string-width": {
            "version": "4.2.3",
            "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz",
            "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==",
            "dev": true,
            "dependencies": {
                "emoji-regex": "^8.0.0",
                "is-fullwidth-code-point": "^3.0.0",
                "strip-ansi": "^6.0.1"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/strip-ansi": {
            "version": "6.0.1",
            "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz",
            "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==",
            "dev": true,
            "dependencies": {
                "ansi-regex": "^5.0.1"
            },
            "engines": {
                "node": ">=8"
            }
        },
        "node_modules/sucrase": {
            "version": "3.35.1",
            "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.1.tgz",
            "integrity": "sha512-DhuTmvZWux4H1UOnWMB3sk0sbaCVOoQZjv8u1rDoTV0HTdGem9hkAZtl4JZy8P2z4Bg0nT+YMeOFyVr4zcG5Tw==",
            "dev": true,
            "dependencies": {
                "@jridgewell/gen-mapping": "^0.3.2",
                "commander": "^4.0.0",
                "lines-and-columns": "^1.1.6",
                "mz": "^2.7.0",
                "pirates": "^4.0.1",
                "tinyglobby": "^0.2.11",
                "ts-interface-checker": "^0.1.9"
            },
            "bin": {
                "sucrase": "bin/sucrase",
                "sucrase-node": "bin/sucrase-node"
            },
            "engines": {
                "node": ">=16 || 14 >=14.17"
            }
        },
        "node_modules/supports-color": {
            "version": "8.1.1",
            "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz",
            "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==",
            "dev": true,
            "dependencies": {
                "has-flag": "^4.0.0"
            },
            "engines": {
                "node": ">=10"
            },
            "funding": {
                "url": "https://github.com/chalk/supports-color?sponsor=1"
            }
        },
        "node_modules/supports-preserve-symlinks-flag": {
            "version": "1.0.0",
            "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz",
            "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==",
            "dev": true,
            "engines": {
                "node": ">= 0.4"
            },
            "funding": {
                "url": "https://github.com/sponsors/ljharb"
            }
        },
        "node_modules/tailwindcss": {
            "version": "3.4.19",
            "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.19.tgz",
            "integrity": "sha512-3ofp+LL8E+pK/JuPLPggVAIaEuhvIz4qNcf3nA1Xn2o/7fb7s/TYpHhwGDv1ZU3PkBluUVaF8PyCHcm48cKLWQ==",
            "dev": true,
            "dependencies": {
                "@alloc/quick-lru": "^5.2.0",
                "arg": "^5.0.2",
                "chokidar": "^3.6.0",
                "didyoumean": "^1.2.2",
                "dlv": "^1.1.3",
                "fast-glob": "^3.3.2",
                "glob-parent": "^6.0.2",
                "is-glob": "^4.0.3",
                "jiti": "^1.21.7",
                "lilconfig": "^3.1.3",
                "micromatch": "^4.0.8",
                "normalize-path": "^3.0.0",
                "object-hash": "^3.0.0",
                "picocolors": "^1.1.1",
                "postcss": "^8.4.47",
                "postcss-import": "^15.1.0",
                "postcss-js": "^4.0.1",
                "postcss-load-config": "^4.0.2 || ^5.0 || ^6.0",
                "postcss-nested": "^6.2.0",
                "postcss-selector-parser": "^6.1.2",
                "resolve": "^1.22.8",
                "sucrase": "^3.35.0"
            },
            "bin": {
                "tailwind": "lib/cli.js",
                "tailwindcss": "lib/cli.js"
            },
            "engines": {
                "node": ">=14.0.0"
            }
        },
        "node_modules/tailwindcss/node_modules/jiti": {
            "version": "1.21.7",
            "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.7.tgz",
            "integrity": "sha512-/imKNG4EbWNrVjoNC/1H5/9GFy+tqjGBHCaSsN+P2RnPqjsLmv6UD3Ej+Kj8nBWaRAwyk7kK5ZUc+OEatnTR3A==",
            "dev": true,
            "bin": {
                "jiti": "bin/jiti.js"
            }
        },
        "node_modules/tapable": {
            "version": "2.3.0",
            "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.0.tgz",
            "integrity": "sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==",
            "dev": true,
            "engines": {
                "node": ">=6"
            },
            "funding": {
                "type": "opencollective",
                "url": "https://opencollective.com/webpack"
            }
        },
        "node_modules/thenify": {
            "version": "3.3.1",
            "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.1.tgz",
            "integrity": "sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==",
            "dev": true,
            "dependencies": {
                "any-promise": "^1.0.0"
            }
        },
        "node_modules/thenify-all": {
            "version": "1.6.0",
            "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz",
            "integrity": "sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==",
            "dev": true,
            "dependencies": {
                "thenify": ">= 3.1.0 < 4"
            },
            "engines": {
                "node": ">=0.8"
            }
        },
        "node_modules/tinyglobby": {
            "version": "0.2.15",
            "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
            "integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
            "dev": true,
            "dependencies": {
                "fdir": "^6.5.0",
                "picomatch": "^4.0.3"
            },
            "engines": {
                "node": ">=12.0.0"
            },
            "funding": {
                "url": "https://github.com/sponsors/SuperchupuDev"
            }
        },
        "node_modules/tinyglobby/node_modules/fdir": {
            "version": "6.5.0",
            "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
            "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
            "dev": true,
            "engines": {
                "node": ">=12.0.0"
            },
            "peerDependencies": {
                "picomatch": "^3 || ^4"
            },
            "peerDependenciesMeta": {
                "picomatch": {
                    "optional": true
                }
            }
        },
        "node_modules/tinyglobby/node_modules/picomatch": {
            "version": "4.0.3",
            "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
            "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
            "dev": true,
            "engines": {
                "node": ">=12"
            },
            "funding": {
                "url": "https://github.com/sponsors/jonschlinkert"
            }
        },
        "node_modules/to-regex-range": {
            "version": "5.0.1",
            "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz",
            "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==",
            "dev": true,
            "dependencies": {
                "is-number": "^7.0.0"
            },
            "engines": {
                "node": ">=8.0"
            }
        },
        "node_modules/tree-kill": {
            "version": "1.2.2",
            "resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz",
            "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==",
            "dev": true,
            "bin": {
                "tree-kill": "cli.js"
            }
        },
        "node_modules/ts-interface-checker": {
            "version": "0.1.13",
            "resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz",
            "integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==",
            "dev": true
        },
        "node_modules/tslib": {
            "version": "2.8.1",
            "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz",
            "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==",
            "dev": true
        },
        "node_modules/update-browserslist-db": {
            "version": "1.2.3",
            "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz",
            "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==",
            "dev": true,
            "funding": [
                {
                    "type": "opencollective",
                    "url": "https://opencollective.com/browserslist"
                },
                {
                    "type": "tidelift",
                    "url": "https://tidelift.com/funding/github/npm/browserslist"
                },
                {
                    "type": "github",
                    "url": "https://github.com/sponsors/ai"
                }
            ],
            "dependencies": {
                "escalade": "^3.2.0",
                "picocolors": "^1.1.1"
            },
            "bin": {
                "update-browserslist-db": "cli.js"
            },
            "peerDependencies": {
                "browserslist": ">= 4.21.0"
            }
        },
        "node_modules/util-deprecate": {
            "version": "1.0.2",
            "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
            "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==",
            "dev": true
        },
        "node_modules/vite": {
            "version": "7.3.0",
            "resolved": "https://registry.npmjs.org/vite/-/vite-7.3.0.tgz",
            "integrity": "sha512-dZwN5L1VlUBewiP6H9s2+B3e3Jg96D0vzN+Ry73sOefebhYr9f94wwkMNN/9ouoU8pV1BqA1d1zGk8928cx0rg==",
            "dev": true,
            "dependencies": {
                "esbuild": "^0.27.0",
                "fdir": "^6.5.0",
                "picomatch": "^4.0.3",
                "postcss": "^8.5.6",
                "rollup": "^4.43.0",
                "tinyglobby": "^0.2.15"
            },
            "bin": {
                "vite": "bin/vite.js"
            },
            "engines": {
                "node": "^20.19.0 || >=22.12.0"
            },
            "funding": {
                "url": "https://github.com/vitejs/vite?sponsor=1"
            },
            "optionalDependencies": {
                "fsevents": "~2.3.3"
            },
            "peerDependencies": {
                "@types/node": "^20.19.0 || >=22.12.0",
                "jiti": ">=1.21.0",
                "less": "^4.0.0",
                "lightningcss": "^1.21.0",
                "sass": "^1.70.0",
                "sass-embedded": "^1.70.0",
                "stylus": ">=0.54.8",
                "sugarss": "^5.0.0",
                "terser": "^5.16.0",
                "tsx": "^4.8.1",
                "yaml": "^2.4.2"
            },
            "peerDependenciesMeta": {
                "@types/node": {
                    "optional": true
                },
                "jiti": {
                    "optional": true
                },
                "less": {
                    "optional": true
                },
                "lightningcss": {
                    "optional": true
                },
                "sass": {
                    "optional": true
                },
                "sass-embedded": {
                    "optional": true
                },
                "stylus": {
                    "optional": true
                },
                "sugarss": {
                    "optional": true
                },
                "terser": {
                    "optional": true
                },
                "tsx": {
                    "optional": true
                },
                "yaml": {
                    "optional": true
                }
            }
        },
        "node_modules/vite-plugin-full-reload": {
            "version": "1.2.0",
            "resolved": "https://registry.npmjs.org/vite-plugin-full-reload/-/vite-plugin-full-reload-1.2.0.tgz",
            "integrity": "sha512-kz18NW79x0IHbxRSHm0jttP4zoO9P9gXh+n6UTwlNKnviTTEpOlum6oS9SmecrTtSr+muHEn5TUuC75UovQzcA==",
            "dev": true,
            "dependencies": {
                "picocolors": "^1.0.0",
                "picomatch": "^2.3.1"
            }
        },
        "node_modules/vite/node_modules/fdir": {
            "version": "6.5.0",
            "resolved": "https://registry.npmjs.org/fdir/-/fdir-6.5.0.tgz",
            "integrity": "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==",
            "dev": true,
            "engines": {
                "node": ">=12.0.0"
            },
            "peerDependencies": {
                "picomatch": "^3 || ^4"
            },
            "peerDependenciesMeta": {
                "picomatch": {
                    "optional": true
                }
            }
        },
        "node_modules/vite/node_modules/picomatch": {
            "version": "4.0.3",
            "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-4.0.3.tgz",
            "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
            "dev": true,
            "engines": {
                "node": ">=12"
            },
            "funding": {
                "url": "https://github.com/sponsors/jonschlinkert"
            }
        },
        "node_modules/wrap-ansi": {
            "version": "7.0.0",
            "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
            "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
            "dev": true,
            "dependencies": {
                "ansi-styles": "^4.0.0",
                "string-width": "^4.1.0",
                "strip-ansi": "^6.0.0"
            },
            "engines": {
                "node": ">=10"
            },
            "funding": {
                "url": "https://github.com/chalk/wrap-ansi?sponsor=1"
            }
        },
        "node_modules/y18n": {
            "version": "5.0.8",
            "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz",
            "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==",
            "dev": true,
            "engines": {
                "node": ">=10"
            }
        },
        "node_modules/yargs": {
            "version": "17.7.2",
            "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz",
            "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==",
            "dev": true,
            "dependencies": {
                "cliui": "^8.0.1",
                "escalade": "^3.1.1",
                "get-caller-file": "^2.0.5",
                "require-directory": "^2.1.1",
                "string-width": "^4.2.3",
                "y18n": "^5.0.5",
                "yargs-parser": "^21.1.1"
            },
            "engines": {
                "node": ">=12"
            }
        },
        "node_modules/yargs-parser": {
            "version": "21.1.1",
            "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz",
            "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==",
            "dev": true,
            "engines": {
                "node": ">=12"
            }
        }
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/package.json ---
{
    "$schema": "https://www.schemastore.org/package.json",
    "private": true,
    "type": "module",
    "scripts": {
        "build": "vite build",
        "dev": "vite"
    },
    "devDependencies": {
        "@tailwindcss/forms": "^0.5.2",
        "@tailwindcss/vite": "^4.0.0",
        "alpinejs": "^3.4.2",
        "autoprefixer": "^10.4.2",
        "axios": "^1.11.0",
        "concurrently": "^9.0.1",
        "laravel-vite-plugin": "^2.0.0",
        "postcss": "^8.4.31",
        "prettier-plugin-blade": "^2.1.21",
        "tailwindcss": "^3.1.0",
        "vite": "^7.0.7"
    }
}

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/.env ---
APP_NAME=Laravel
APP_ENV=local
APP_KEY=base64:jb/WIIcnXa1LfuZA2uBGgCd7aW5yiEBj4N2pakSg/8Y=
APP_DEBUG=true
APP_URL=http://localhost

APP_LOCALE=en
APP_FALLBACK_LOCALE=en
APP_FAKER_LOCALE=en_US

APP_MAINTENANCE_DRIVER=file
# APP_MAINTENANCE_STORE=database

# PHP_CLI_SERVER_WORKERS=4

BCRYPT_ROUNDS=12

LOG_CHANNEL=stack
LOG_STACK=single
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=110.4.45.212
DB_PORT=3306
DB_DATABASE=giovana_maxtop_staging
DB_USERNAME=giovana_maxtop_staging
DB_PASSWORD=giovana_maxtop_staging

SESSION_DRIVER=database
SESSION_LIFETIME=120
SESSION_ENCRYPT=false
SESSION_PATH=/
SESSION_DOMAIN=null

BROADCAST_CONNECTION=log
FILESYSTEM_DISK=local
QUEUE_CONNECTION=database

CACHE_STORE=database
# CACHE_PREFIX=

MEMCACHED_HOST=127.0.0.1

REDIS_CLIENT=phpredis
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379

MAIL_MAILER=log
MAIL_SCHEME=null
MAIL_HOST=127.0.0.1
MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_FROM_ADDRESS="hello@example.com"
MAIL_FROM_NAME="${APP_NAME}"

AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=
AWS_USE_PATH_STYLE_ENDPOINT=false

VITE_APP_NAME="${APP_NAME}"

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/postcss.config.js ---
export default {
    plugins: {
        tailwindcss: {},
        autoprefixer: {},
    },
};

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/routes/auth.php ---
<?php

use App\Http\Controllers\Auth\AuthenticatedSessionController;
use App\Http\Controllers\Auth\NewPasswordController;
use App\Http\Controllers\Auth\PasswordController;
use App\Http\Controllers\Auth\PasswordResetLinkController;
use App\Http\Controllers\Auth\RegisteredUserController;
use Illuminate\Support\Facades\Route;

Route::middleware('guest')->group(function () {
    // Route::get('register', [RegisteredUserController::class, 'create'])
    //     ->name('register');

    // Route::post('register', [RegisteredUserController::class, 'store']);

    Route::get('login', [AuthenticatedSessionController::class, 'create'])
        ->name('login');

    Route::post('login', [AuthenticatedSessionController::class, 'store']);

    Route::get('forgot-password', [PasswordResetLinkController::class, 'create'])
        ->name('password.request');

    Route::post('forgot-password', [PasswordResetLinkController::class, 'store'])
        ->name('password.email');

    Route::get('reset-password/{token}', [NewPasswordController::class, 'create'])
        ->name('password.reset');

    Route::post('reset-password', [NewPasswordController::class, 'store'])
        ->name('password.store');
});

Route::middleware('auth')->group(function () {

    Route::put('password', [PasswordController::class, 'update'])->name('password.update');

    Route::post('logout', [AuthenticatedSessionController::class, 'destroy'])
        ->name('logout');
});

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/routes/console.php ---
<?php

use Illuminate\Foundation\Inspiring;
use Illuminate\Support\Facades\Artisan;

Artisan::command('inspire', function () {
    $this->comment(Inspiring::quote());
})->purpose('Display an inspiring quote');

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/routes/web.php ---
<?php

use App\Http\Controllers\ActivityLogController;
use App\Http\Controllers\DashboardController;
use App\Http\Controllers\ProfileController;
use App\Http\Controllers\RoleManagerController;
use App\Http\Controllers\UserController;
use Illuminate\Support\Facades\Route;

/*
|--------------------------------------------------------------------------
| Public Routes
|--------------------------------------------------------------------------
*/
Route::get('/', function () {
    return redirect()->route('login');
});

require __DIR__.'/auth.php';

/*
|--------------------------------------------------------------------------
| Protected Routes (Logged In Users)
|--------------------------------------------------------------------------
*/
Route::middleware(['auth'])->group(function () {

    // DASHBOARD
    Route::get('/dashboard', [DashboardController::class, 'index'])->name('dashboard');

    /**
     * Profile Management Routes
     * Fulfills standard user self-service requirements.
     */
    Route::get('/profile', [ProfileController::class, 'edit'])->name('profile.edit');
    Route::patch('/profile', [ProfileController::class, 'update'])->name('profile.update');
    Route::delete('/profile', [ProfileController::class, 'destroy'])->name('profile.destroy');

    // USER MANAGEMENT
    // We split this because viewing and creating require different permissions.
    Route::prefix('users')->name('users.')->group(function () {

        // List Users (Requires 'view_users' permission)
        Route::get('/', [UserController::class, 'index'])
            ->middleware('permission:view_login_credentials')
            ->name('index');

        // Create New User (Requires 'create_users' permission)
        Route::middleware('permission:create_users')->group(function () {
            Route::get('/create', [UserController::class, 'create'])->name('create');
            Route::post('/', [UserController::class, 'store'])->name('store');
        });

        // EDIT USER (Requires 'edit_users' permission)
        Route::middleware('permission:edit_users|edit_assigned_customers')->group(function () {
            Route::get('/{user}/edit', [UserController::class, 'edit'])->name('edit');
            Route::put('/{user}', [UserController::class, 'update'])->name('update');
            Route::delete('/{user}', [UserController::class, 'destroy'])->name('destroy');

        });

        // BUSINESS ENTITY MANAGEMENT [Addendum 3.c]
        // ARCHITECTURE FIX: Wrapped resource in specific permission middleware
        Route::middleware('permission:view_business_entities')->group(function () {
            Route::resource('companys', \App\Http\Controllers\CompanyController::class);
        });
    });

    // MY CUSTOMER
    Route::get('/my-customers', [UserController::class, 'assignedIndex'])
        ->middleware('permission:view_assigned_customers')
        ->name('users.assigned');

    // SYSTEM SETTINGS (Strict Admin Only)
    /**
     * Fulfills Backbone Section 2.a: Administrator (Developers Only)
     * ARCHITECTURE FIX: Added name prefix 'admin.' to resolve RouteNotFoundException.
     */
    Route::middleware('role:admin')->prefix('admin')->name('admin.')->group(function () {

        // Feature Settings (Feature Matrix)
        Route::name('roles.')->group(function () {
            Route::get('/matrix', [RoleManagerController::class, 'index'])->name('matrix');
            Route::post('/matrix', [RoleManagerController::class, 'update'])->name('update');

            // ARCHITECTURE FIX: Role CRUD for Custom Roles [Backbone 2.f]
            // This now generates 'admin.roles.manage.index'
            Route::resource('manage', \App\Http\Controllers\Admin\RoleController::class)->except(['show']);
        });

        // Activity Log Route: Results in 'admin.activity.index'
        Route::get('/activity-logs', [ActivityLogController::class, 'index'])->name('activity.index');

    });

    // Only Admin & CS accessible
    Route::middleware(['role:cs_staff|cs_leader|admin'])->prefix('office')->name('office.')->group(function () {

        // 1. Static Registry Routes
        Route::get('/orders/queue', [\App\Http\Controllers\CS\OrderManagementController::class, 'queue'])->name('orders.queue');
        Route::get('/orders/history', [\App\Http\Controllers\CS\OrderManagementController::class, 'history'])->name('orders.history');
        Route::get('/orders/cancellation-requests', [\App\Http\Controllers\CS\OrderManagementController::class, 'cancellationRequests'])->name('orders.cancellations')->middleware('role:admin|cs_leader');

        // FIX: Moved 'orders/all' above wildcard to ensure proper resolution [Backbone 2.a]
        Route::get('/orders/all', [\App\Http\Controllers\CS\OrderManagementController::class, 'allOrders'])
            ->name('orders.all')
            ->middleware('role:admin|cs_leader');

        // 2. Resource Index
        Route::get('/orders', [\App\Http\Controllers\CS\OrderManagementController::class, 'index'])->name('orders.index');

        // 3. Wildcard Routes (MUST BE LAST)
        Route::get('/orders/{order}', [\App\Http\Controllers\CS\OrderManagementController::class, 'show'])->name('orders.show');
        Route::post('/orders/{order}/claim', [\App\Http\Controllers\CS\OrderManagementController::class, 'claim'])->name('orders.claim');
        Route::post('/orders/{order}/approve', [\App\Http\Controllers\CS\OrderManagementController::class, 'approve'])->name('orders.approve');
        Route::post('/orders/{order}/cancel', [\App\Http\Controllers\CS\OrderManagementController::class, 'cancel'])->name('orders.cancel');
        Route::put('/orders/{order}/status', [\App\Http\Controllers\CS\OrderManagementController::class, 'updateStatus'])->name('orders.updateStatus');
        Route::post('/orders/{order}/handover', [\App\Http\Controllers\CS\OrderManagementController::class, 'handover'])->name('orders.handover');

    });

    // ITEM MANAGEMENT
    Route::resource('items', \App\Http\Controllers\ItemController::class)
        ->middleware(['auth', 'verified']);

    // CATALOG MANAGEMENT
    Route::resource('catalogs', \App\Http\Controllers\CatalogController::class)
        ->middleware(['auth', 'verified']);

    // Fulfills Addendum Section 3.a & 3.c: Company Management Module
    // This resolves the Route [companys.index] not defined error.
    Route::resource('companys', \App\Http\Controllers\CompanyController::class)
        ->middleware(['auth', 'verified']);

    // Fulfills Requirement: Item Categories Management
    Route::resource('categories', \App\Http\Controllers\CategoryController::class)
        ->middleware(['auth', 'verified']);

    // CUSTOMER PRODUCT VIEWING
    // 1. Product Catalog visibility (whitelist logic) [1]
    Route::get('/products', [\App\Http\Controllers\Customer\ProductCatalogController::class, 'index'])
        ->name('customer.products.index')
        ->middleware('role:customer');

    Route::middleware('role:customer')->group(function () {

        // 2. Reservation / Draft Management (reservation. index, store, etc.) [1, 2]
        Route::prefix('reservation')->name('reservation.')->group(function () {
            Route::get('/', [\App\Http\Controllers\Customer\ReservationController::class, 'index'])->name('index');
            Route::post('/add', [\App\Http\Controllers\Customer\ReservationController::class, 'store'])->name('store');
            Route::put('/{orderItem}', [\App\Http\Controllers\Customer\ReservationController::class, 'update'])->name('update');
            Route::delete('/{orderItem}', [\App\Http\Controllers\Customer\ReservationController::class, 'destroy'])->name('destroy');
            Route::post('/submit', [\App\Http\Controllers\Customer\ReservationController::class, 'submit'])->name('submit');
            Route::post('/{order}/recall', [\App\Http\Controllers\Customer\ReservationController::class, 'recall'])->name('recall');
        });

        // 3. Order History (customer.orders. index, show) [3]
        // Move these OUTSIDE the 'reservation.' name group to fix the naming error
        Route::prefix('my-orders')->name('customer.orders.')->group(function () {
            Route::get('/', [\App\Http\Controllers\Customer\OrderHistoryController::class, 'index'])->name('index');
            Route::get('/{order}', [\App\Http\Controllers\Customer\OrderHistoryController::class, 'show'])->name('show');
        });
    });

});

--- END_FILE ---

--- START_FILE: /Users/ahwei/Desktop/Work+/Freelance+/Maxtop e-ordering system/composer.json ---
{
    "$schema": "https://getcomposer.org/schema.json",
    "name": "laravel/laravel",
    "type": "project",
    "description": "The skeleton application for the Laravel framework.",
    "keywords": ["laravel", "framework"],
    "license": "MIT",
    "require": {
        "php": "^8.2",
        "laravel/framework": "^12.0",
        "laravel/tinker": "^2.10.1",
        "spatie/laravel-activitylog": "^4.10",
        "spatie/laravel-permission": "^6.24"
    },
    "require-dev": {
        "fakerphp/faker": "^1.23",
        "laravel/breeze": "^2.3",
        "laravel/pail": "^1.2.2",
        "laravel/pint": "^1.24",
        "laravel/sail": "^1.41",
        "mockery/mockery": "^1.6",
        "nunomaduro/collision": "^8.6",
        "pestphp/pest": "^3.8",
        "pestphp/pest-plugin-laravel": "^3.2"
    },
    "autoload": {
        "psr-4": {
            "App\\": "app/",
            "Database\\Factories\\": "database/factories/",
            "Database\\Seeders\\": "database/seeders/"
        }
    },
    "autoload-dev": {
        "psr-4": {
            "Tests\\": "tests/"
        }
    },
    "scripts": {
        "setup": [
            "composer install",
            "@php -r \"file_exists('.env') || copy('.env.example', '.env');\"",
            "@php artisan key:generate",
            "@php artisan migrate --force",
            "npm install",
            "npm run build"
        ],
        "dev": [
            "Composer\\Config::disableProcessTimeout",
            "npx concurrently -c \"#93c5fd,#c4b5fd,#fb7185,#fdba74\" \"php artisan serve\" \"php artisan queue:listen --tries=1\" \"php artisan pail --timeout=0\" \"npm run dev\" --names=server,queue,logs,vite --kill-others"
        ],
        "test": [
            "@php artisan config:clear --ansi",
            "@php artisan test"
        ],
        "post-autoload-dump": [
            "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
            "@php artisan package:discover --ansi"
        ],
        "post-update-cmd": [
            "@php artisan vendor:publish --tag=laravel-assets --ansi --force"
        ],
        "post-root-package-install": [
            "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "@php artisan key:generate --ansi",
            "@php -r \"file_exists('database/database.sqlite') || touch('database/database.sqlite');\"",
            "@php artisan migrate --graceful --ansi"
        ],
        "pre-package-uninstall": [
            "Illuminate\\Foundation\\ComposerScripts::prePackageUninstall"
        ]
    },
    "extra": {
        "laravel": {
            "dont-discover": []
        }
    },
    "config": {
        "optimize-autoloader": true,
        "preferred-install": "dist",
        "sort-packages": true,
        "allow-plugins": {
            "pestphp/pest-plugin": true,
            "php-http/discovery": true
        }
    },
    "minimum-stability": "stable",
    "prefer-stable": true
}

--- END_FILE ---

