<?php
/// file: database/migrations/004_create_services.php

declare(strict_types=1);


return static function (PDO $pdo): void {
    $pdo->exec('CREATE TABLE IF NOT EXISTS services (
      id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
      title VARCHAR(255) NOT NULL,
      slug VARCHAR(255) NOT NULL UNIQUE,
      short_description TEXT NOT NULL,
      detail TEXT NOT NULL,
      process TEXT NOT NULL,
      deliverables TEXT NOT NULL,
      ideal_client TEXT NOT NULL,
      sort_order INT NOT NULL DEFAULT 0,
      status ENUM(\'draft\',\'published\') NOT NULL DEFAULT \'published\',
      created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
      updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci');
};
