CREATE TABLE ship_messages (
    id INTEGER PRIMARY KEY AUTOINCREMENT,
    timestamp TEXT NOT NULL,
    subsystem TEXT NOT NULL,
    severity TEXT CHECK(severity IN ('CRITICAL', 'ALERT', 'WARNING', 'NOTICE', 'INFO')) NOT NULL DEFAULT 'INFO',
    color TEXT NOT NULL,
    message TEXT NOT NULL
);

CREATE TABLE crew_member (
    id INTEGER PRIMARY KEY AUTOINCREMENT,
    rank TEXT NOT NULL,
    name TEXT NOT NULL
);