-- Optional operator-configured regional spend guard. A missing row means -- unlimited, preserving existing deployments until they opt into a quota. CREATE TABLE allocation_quotas ( region TEXT PRIMARY KEY CHECK (region IN ('EU', 'NA')), window_started_at TIMESTAMPTZ NOT NULL, window_seconds INTEGER NOT NULL CHECK (window_seconds > 0), used_allocations INTEGER NOT NULL DEFAULT 0 CHECK (used_allocations >= 0), max_allocations INTEGER NOT NULL CHECK (max_allocations > 0), updated_at TIMESTAMPTZ NOT NULL );