body { margin: 0px; } #canvas-paint, #canvas-pdf { margin:auto; position:absolute; top:0; bottom:0; left:0; right:0; max-height:100%; max-width:100%; padding-bottom:0px; margin-bottom:0px; }