/*
 * Open Software License ("OSL") v 3.0
 * Copyright (c) 2019 kamalasaurus
 */

html, body, div.layout {
  margin: 0;
  padding: 0;
  max-width: 100%;
  max-height: 100%;
  background-color: rgb(159, 179, 190);
  font-family: 'Monaco', 'Courier', monospace;
  overflow: hidden;
}

form.new {
  display: block;
  margin: 20vh auto;
  padding: 8vh;
  max-height: 60vh;
  max-width: 40vw;
  background-color: rgb(235, 245, 255);
}

form.new > * {
  display: block;
}

form.new div.title {
  text-align: center;
}

form.new select {
  font-size: 12px;
}

form.new object.logo {
  display: inline-block;
}

form.new .submit-container {
  text-align: right;
}

button {
  height: 3em;
  cursor: pointer;
  padding: 0 1em;
  display: inline-block;
}

canvas.surface {
  display: block;
  position: relative;
  margin: 0 auto;
  max-width: 100vw;
  max-height: 100vh;
  height: calc(100% / (var(--aspect-ratio)));
  cursor: url(app/icons/cursors/Pencil.png) 0 16, auto;
}

canvas.surface.eraser {
  cursor: url(app/icons/cursors/Eraser.png) 0 24, auto;
}

div.controls {
  position: absolute;
  top: 0;
  left: 0;
  width: 75px;
}

div.controls > div.button {
  position: relative;
  box-sizing: border-box;
  width: 75px;
  height: 75px;
  line-height: 75px;
  display: inline-block;
  cursor: pointer;
  background-color: #333;
  vertical-align: middle;
  text-align: center;
}

div.controls > div.button:not(:last-child) {
  border-bottom: 1px solid #bbb;
}

div.controls > div.button img.icon {
  display: inline-block;
  padding-top: 12.5px;
  opacity: 0.75;
}

div.controls > div.button:hover {
  background-color: turquoise;
}

div.controls > div.button.active {
  border: 1px solid yellow;
}

div.controls > div.button > div.control-panel {
  position: absolute;
  text-align: left;
  top: -15px;
  left: 85px;
  display: none;
  cursor: default;
}

div.controls > div.button.active > div.control-panel {
  display: block;
}

div.controls > div.button > div.control-panel > textarea.add-button {
  width: 320px;
  height: 145px;
}

