.popup-container {
  position: absolute;
}
.popup-container {
  visibility: hidden;
}
.popup-container.is-visible {
  visibility: visible;
}

/**/

.context-menu-container {
  top: 0px;
  left: 0px;
  position: absolute;
  transform: translateX(0) translateY(0) translateZ(0);

  pointer-events: none; /* no pointer events until animated visible */
  z-index: 999;
}

#context-menu {
  position: relative;
  background: rgba(20,20,20,1);
  color: white;
  padding: 10px;
  border-radius: 8px;
  max-width: 300px;
  
  transform-origin: 50% 100%;

    opacity: 0;
  animation-duration: 0.25s;
  animation-timing-function: ease-out;
  animation-iteration-count: 1;
  animation-fill-mode: forwards;
  float: left;
}

#context-menu.top-nub:after {
  bottom: 100%;
  left: 50%;
  border: solid transparent;
  content: " ";
  height: 0;
  width: 0;
  position: absolute;
  pointer-events: none;
  border-bottom-color: rgba(20,20,20,1);
  border-width: 10px;
  margin-left: -10px;
}

#context-menu.bottom-nub:after {
  top: 100%;
  left: 50%;
  border: solid transparent;
  content: " ";
  height: 0;
  width: 0;
  position: absolute;
  pointer-events: none;
  border-top-color: rgba(20,20,20,1);
  border-width: 10px;
  margin-left: -10px;
  z-index: 2000;
}

#context-menu.left-nub:after {
  right: 100%;
  top: 50%;
  border: solid transparent;
  content: " ";
  height: 0;
  width: 0;
  position: absolute;
  pointer-events: none;
  border-right-color: rgba(20,20,20,1);
  border-width: 10px;
  margin-top: -10px;
}

#context-menu.right-nub:after {
  left: 100%;
  top: 50%;
  border: solid transparent;
  content: " ";
  height: 0;
  width: 0;
  position: absolute;
  pointer-events: none;
  border-left-color: rgba(0,0,0,0.5);
  border-width: 10px;
  margin-top: -10px;
  z-index: 2000;
}

#context-menu .item {
  color: rgba(255,255,255,0.5);
  padding: 5px 10px;
  border-radius: 3px;
}

#context-menu .hr {
  border-top: 1px solid rgba(255,255,255,0.1);
  margin: 10px 0;
}


#context-menu .item:hover {
  background-color: rgba(255,255,255,0.2);
}


#context-menu .title {
  font-weight: 500;
  font-size: 20px;
  opacity: 0.8;
}

#context-menu .description {
  font-weight: 100;
  font-size: 16px;
  opacity: 0.5;
}

#context-menu .key-command {
  float: right;
  margin-right: -6px;
  margin-left: 10px;
  color: rgba(255,255,255,0.5);
}

.appear-anim {
  /* see: tooltip.css */
  animation-name: appear;
  pointer-events: auto;
}


.color-picker-container { 
  top: 0px;
  left: 0px;
  position: absolute;
  transform: translateX(0) translateY(0) translateZ(0);

  pointer-events: none; /* no pointer events until animated visible */
  z-index: 999;
}

.color-picker-container #context-menu {
  max-width: 1000px;
  transform-origin: 50% 0;
}


.color-picker-container .color-row {
  height: 20px;
}

.color-swatch {
  display: inline-block;
  width: 20px;
  height: 20px;
}

.last-color {
  width: 60px;
}

@media only screen and (min-width: 1983px) {
  .color-picker-container .color-row {
    height: 40px;
  }

  .color-swatch {
    width: 40px;
    height: 40px;
  }

  .last-color {
    width: 120px;
  }
}

.color-swatch.active {
  border: 4px solid rgba(255,255,255,0.5);
  box-sizing: border-box;
  box-shadow: 0 0 15px rgba(0,0,0,0.4);
  z-index: 2000;
  position: relative;
}

.color-picker-container .color-name {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  padding-top: 10px;
}

.color-picker-container .color-name .color-css {
  color: rgba(255,255,255,0.3);
  margin-left: 10px;
  box-sizing: border-box;
  width: 80px;
  border: 0;
  border-radius: 3px;
  background: rgba(0,0,0,0);
  font-size: 14px;
  font-weight: 100;
  padding: 5px;
  resize: none;
  text-transform: uppercase;
}

.color-picker-container .color-name .color-css:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.3);
}
