body {
  margin: 0;
}

canvas {
  aspect-ratio: auto;
  transform-origin: 0 0;
}

html, body, div, canvas {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

html, body, div, canvas {
  touch-action: none;
  box-sizing: border-box;
}

body {
  font: 26px Arial, sans-serif;
}

.app {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex-direction: row;
  width: 100%;
  height: 100%;
}

.main {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: column;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
}

.sidebar {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  align-items: flex-start;
  flex-basis: auto;
  width: 25%;
  min-width: 80px;
  max-width: 100%;
  height: 100%;
  background-color: #111111;
}

.sidebar-resize-handle {
  flex: 0 0 auto;
  align-self: auto;
  flex-basis: auto;
  touch-action: none;
  width: 8px;
  height: 10%;
  border-radius: 3px;
  align-self: center;
  background-color: white;
  cursor: col-resize;
}
.sidebar-resize-handle:hover {
  filter: brightness(1.5);
}

.sidebar-internal {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  flex-grow: 1;
}

.sidebar-controls {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  width: 100%;
  height: 100%;
  flex-basis: content;
  align-items: start;
  gap: 5px;
}

.sidebar-control-button {
  flex: 0 0 auto;
  align-self: auto;
  flex-basis: auto;
  width: 35px;
  height: 35px;
  border-radius: 15%;
  margin: 10px;
  background-color: red;
}

.sidebar-control-title {
  font-size: 45px;
  padding: 28px 40px;
  color: grey;
}

.sidebar-content {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  flex-grow: 1;
}

.bar {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  flex-wrap: wrap;
  width: 100%;
  padding: 7px;
  gap: 10px 25px;
  background: #111111;
}

.bar-group {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 7px;
}

.bar-button, .bar-accent-button {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  justify-content: center;
  align-items: center;
  padding: 6px 15px;
  border-radius: 10px;
  border: solid #444444 4px;
  user-select: none;
  background: #444444;
  color: #e1e1d9;
}
.bar-button:hover, .bar-accent-button:hover {
  filter: brightness(1.25);
}
.bar-button:active, .bar-accent-button:active {
  filter: brightness(1.5);
}

.bar-accent-button {
  background: #222222;
  border-color: #222222;
}

.bar-text {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  font: 26px Arial, sans-serif;
  padding: 6px 12px;
  width: 270px;
  border-radius: 6px;
}

.workspace {
  overflow: hidden;
  position: relative;
  flex: 0 0 auto;
  align-self: auto;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  background: #333333;
}

.canvas1 {
  position: absolute;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 1;
  background: #333333;
}

.canvas2 {
  position: absolute;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 2;
  background: transparent;
}

.canvas3 {
  position: absolute;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 3;
  background: transparent;
}

.canvas4 {
  position: absolute;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 4;
  background: transparent;
}

.icon {
  width: 28px;
  height: 28px;
}

.choice-active {
  border-color: blue;
}

.selection-frame {
  position: absolute;
  overflow: visible;
  touch-action: none;
  z-index: 20;
}

.selection-canvas {
  position: absolute;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 21;
  background-color: transparent;
}

.selection-outline {
  position: absolute;
  overflow: visible;
  touch-action: none;
  width: 100%;
  height: 100%;
  box-sizing: content-box;
  padding: 50px;
  margin: -50px;
  z-index: 22;
}

.selection-border {
  position: absolute;
  overflow: visible;
  touch-action: none;
  width: 100%;
  height: 100%;
  box-sizing: content-box;
  border: dashed gray 2px;
  margin: -52px;
  z-index: 23;
  opacity: 50%;
}

.control-knob {
  position: absolute;
  touch-action: none;
  z-index: 24;
  top: 50%;
  left: 50%;
  width: 50px;
  height: 50px;
  transform: translate(-50%, -50%);
  overflow: visible;
}

.move-button {
  position: absolute;
  touch-action: none;
  z-index: 24;
  background-color: gray;
  opacity: 50%;
  width: 100%;
  height: 100%;
}

.resize-button {
  position: absolute;
  touch-action: none;
  z-index: 24;
  background-color: gray;
  opacity: 50%;
  bottom: 0;
  right: 0;
  width: 25px;
  height: 25px;
}

.context-menu {
  position: absolute;
  left: 55px;
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  align-items: flex-start;
  gap: 5px;
  z-index: 30;
}

.context-menu-quick-section {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  gap: 5px;
}

.context-menu-section {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  align-items: flex-start;
  gap: 3px;
  min-width: 100%;
}

.context-menu-button {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  justify-content: center;
  align-items: center;
  user-select: none;
  border-radius: 4px;
  background-color: #111111;
  color: #e1e1d9;
  opacity: 100%;
  align-items: flex-start;
  height: 45px;
  padding: 0 20px;
  min-width: 100%;
}
.context-menu-button:hover {
  filter: brightness(1.25);
}
.context-menu-button:active {
  filter: brightness(1.5);
}

.context-menu-quick-button {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  justify-content: center;
  align-items: center;
  user-select: none;
  border-radius: 4px;
  background-color: #111111;
  color: #e1e1d9;
  opacity: 100%;
  width: 50px;
  height: 50px;
}
.context-menu-quick-button:hover {
  filter: brightness(1.25);
}
.context-menu-quick-button:active {
  filter: brightness(1.5);
}

.settings-view {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  flex-direction: column;
  align-items: flex-start;
  overflow-y: scroll;
  scrollbar-color: #252525 #111111;
  gap: 20px;
  padding: 30px;
}

.settings-checkbox {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  flex-direction: row;
  color: white;
}

.settings-checkbox > input[type=checkbox] {
  flex: 0 0 auto;
  align-self: auto;
  height: 100%;
  width: 22px;
  margin: 0px 15px;
}

.conflict-view {
  overflow: hidden;
  display: flex;
  width: fit-content;
  height: fit-content;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  flex-wrap: nowrap;
  align-content: center;
  row-gap: 0;
  column-gap: 0;
  flex: 0 0 auto;
  align-self: auto;
  width: 100%;
  height: 100%;
  flex: 1 1 100%;
  flex-direction: column;
  align-items: flex-start;
  overflow-y: scroll;
  scrollbar-color: #252525 #111111;
  gap: 10px;
  padding: 30px;
}

.conflict-element {
  flex: 0 0 auto;
  align-self: auto;
  padding: 10px;
  color: white;
  background-color: #222222;
}
