* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html, body {
  min-height: 100%;
  width: 100vw;
  overflow: hidden;
}

#credit {
    position: absolute;
    top: 0;
    right: 0;
    padding: 10px;
    z-index: 5;
    background: rgba(177, 177, 177, 0.8);
    margin-right: 12px;
    margin-top: 12px;
	font-size: 14px;
}
#credit:hover{
background: #e6c85b;
}

.pen {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  border: 1px solid #000;
  transform: translate(-50%,-50%);
  z-index: 1000;
  pointer-events: none;
  box-shadow: 0 0 0 2px #fff, inset 0 0 0 2px #fff;
  transition: opacity .5s;
  opacity: .7;
}
body:active .pen {
  opacity: .2;
}

.guide {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 4;
  border-top: 1px solid rgba(0,0,0,.2);
  width: 1000px;
  height: 1px;
  transform-origin: 0 0;
  transition: opacity .5s;
  pointer-events: none;
}
#masterCanvas {
  position: absolute;
  top: -99999px;
  left: -99999px;
}
#masterCanvas canvas.fg {
  display: none;
}
#masterCanvas.test {
  top: 0;
  left: 0;
  transform-origin: 0 0;
  transform: scale(.2);
}
#masterCanvas.test canvas {
  display: block;
  border: 1px solid red;
}


#canvases .canvas {
  position: absolute;
  top: 50%;
  left: 50%;
  height: 1000px;
  width: 2000px;
  margin-top: -500px;
  margin-left: -1000px;
  z-index: 3;
}
#canvases canvas {
  position: absolute;
  z-index: 3;
}
#canvases .canvas .fg {
  z-index: 5;
  cursor: none;
  opacity: 0;
}

.settings  {
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: 500;
  background: rgba(255,255,255,.8);
}
.settings * {
  margin: 10px 0 10px 10px;
  float: left;
  font-size: .8rem;
  line-height: 1em;
  cursor: default;
  outline: 0;
  color: #000;
}
.settings > div {
  margin: 0;
  position: relative;
}
.settings div span {
  margin: 0;
  position: absolute;
  top: -.8em;
    font-size: 12px;
  min-width: 100%;
  background: rgba(255,255,255,.8);
  padding: 4px 0 4px 10px;
      color: #a0a0a0;
}
input[type=number] {
  width: 3rem;
  padding: 0 0 0 5px;
  font-size: 1.7em;
  border-width: 1px;
}
.jscolor {
  width: 3.8rem;
  text-indent: -99999px;
  padding: 0 0 5px;
  font-size: 1.7em;
  border-width: 1px;
}
input[type=checkbox] {
  margin-top: 1.7em;
  margin-left: 20px;
}
.settings label {
  z-index: 2;
  position: relative;
  line-height: 1.45em;
  padding: 10px 10px 10px 30px;
  margin: 10px 0 10px -25px;
}
.settings button,
.settings a {
  line-height: 1.45em;
  padding: 10px 10px;
  background: rgba(0,0,0,.1);
}
.settings button:hover,
.settings a:hover {
    color: #fff;
    background: #e6c85b;
}
.settings input:hover {
  background: rgba(0,0,0,.1);
}
.settings label:hover {
  background: rgba(0,0,0,.1);
}
.hiddenDownload,
.hiddenColor,
.hiddenSize {
  position: absolute;
  top: -99999px;
  left: -99999px;
}

@media (max-width: 501px) {
  .settings > * {
    clear: left;
  }
}