-- Migration: Create employees table
-- Version: 001
-- Date: 2025-07-27

CREATE TABLE IF NOT EXISTS employees (
    id CHAR(36) PRIMARY KEY,
    slug VARCHAR(50) UNIQUE NOT NULL,
    name VARCHAR(100) NOT NULL,
    title VARCHAR(150) NOT NULL,
    role VARCHAR(100) NOT NULL,
    tagline VARCHAR(255) DEFAULT NULL,
    bio TEXT NOT NULL,
    mythology TEXT NOT NULL,
    avatar_url VARCHAR(500) DEFAULT NULL,
    accent_color VARCHAR(7) DEFAULT NULL,
    symbol VARCHAR(50) DEFAULT NULL,
    skills JSON DEFAULT NULL,
    quote VARCHAR(500) DEFAULT NULL,
    sort_order INT DEFAULT 0,
    created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,

    INDEX idx_employees_slug (slug),
    INDEX idx_employees_sort_order (sort_order)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
