-- 012_dashboard_layout.sql
-- Single global, owner-scoped dashboard layout. One logical row keyed by a
-- stable owner key (v2 is single-owner; 'owner' is the only key for now).
CREATE TABLE dashboard_layout (
  owner_key   text PRIMARY KEY DEFAULT 'owner',
  card_order  jsonb NOT NULL DEFAULT '[]'::jsonb,   -- ["clock","weather",...]
  hidden      jsonb NOT NULL DEFAULT '[]'::jsonb,   -- ["speedtest"]
  sizes       jsonb NOT NULL DEFAULT '{}'::jsonb,   -- {"weather":"s"}
  updated_at  timestamptz NOT NULL DEFAULT now()
);
