@keyframes pop-upwards{
  0% {
    transform:matrix(.97,0,0,1,0,12);
    opacity:0;
  }
  20% {
    transform:matrix(.99,0,0,1,0,2);
    opacity:.7;
  }
  40% {
    transform:matrix(1,0,0,1,0,-1);
    opacity:1;
  }
  70% {
    transform:matrix(1,0,0,1,0,0);
    opacity:1;
    }
  100% {
    transform:matrix(1,0,0,1,0,0);
    opacity:1;
  }
}

@keyframes pop-downwards{0%{transform:matrix(.97,0,0,1,0,-12);opacity:0}20%{transform:matrix(.99,0,0,1,0,-2);opacity:.7}40%{transform:matrix(1,0,0,1,0,1);opacity:1}70%{transform:matrix(1,0,0,1,0,0);opacity:1}100%{transform:matrix(1,0,0,1,0,0);opacity:1}}


$toolbar-color: #323845;


.md-editor-toolbar {
  background: $toolbar-color;
  color: #fff;
  cursor: auto;
  border-radius: 5px;
  z-index: 2;
  position: absolute;
  transition: all 0.1s ease;
  visibility: hidden;
  box-shadow: 0 1px 3px 0 #747171;
  // background-image: linear-gradient(to bottom,rgba(49,49,47,.99),#262625);

  // transition: top 75ms ease-out,left 75ms ease-out;

  &.md-editor-toolbar--isopen {
    visibility: visible;
    // transition: top 75ms ease-out,left 75ms ease-out;
    // animation: pop-upwards 180ms forwards linear;
  }

  &.md-editor-toolbar--linkinput {
    // display:block;
    animation: pop-downwards 200ms forwards linear;
  }

  &::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 50%;
    margin-left: -5px;
    border-top: 5px solid $toolbar-color;
    border-right: 5px solid transparent;
    border-left: 5px solid transparent;
  }

  .md-url-input {
    box-sizing: border-box;
    border-radius: 2px;
    display: block;
    width: 100%;
    padding: 5px;
    padding-right: 11px;
    border: none;
    background: $toolbar-color;
    color: #fff;
    font-size: 0.9em;
    font-weight: 100;

    &:focus {
      outline: none;
      // border-color: #50FF4D;
      // background-color: #eee;
    }
  }

  .md-url-input-close {
    position: absolute;
    right: 8px;
    top: 2.5px;
    font-size: 20px;
    cursor: pointer;
  }
}

.md-editor-toolbar-edit-link {
  padding: 4px 5px;
  font-size: 0.8em;
  width: 320px;

  a {
    color: #fff;
    text-decoration: none;
  }

  &::after {
    bottom: initial;
    top: -5px;
    transform: rotate(180deg);
  }

  button {
    background: none;
    border: none;
    color: #fff;
    float: right;
    display: inline-block;
    padding: 0 5px;
    margin: 5px 0;
    cursor: pointer;

    &.md-editor-toolbar-edit-button {
      border-right: 1px solid #fff;
    }
  }
}

.md-RichEditor-controls {
  font-family: 'Helvetica', sans-serif;
  font-size: 14px;
  display: inline-block;
  border-right: 1px solid #555;
  position: relative;

  &.md-RichEditor-show-link-input {
    padding: 6px 10px;
  }

  &:last-child {
    border-right: none;
  }

  .md-RichEditor-linkButton {
    padding: 0 5px;
    color: #fff;
    text-decoration: none;
  }
}

.md-RichEditor-styleButton {
  color: #fff;
  cursor: pointer;
  display: inline-block;
  padding: 6px 10px;

  &:hover {
    color: yellow;
  }

  &:last-child {
    margin-right: 0;
  }

  &.md-RichEditor-styleButton-bold {
    font-weight: bold;
  }
  &.md-RichEditor-styleButton-italic {
    font-style: italic;
  }
  &.md-RichEditor-styleButton-underline {
    text-decoration: underline;
  }
  &.md-RichEditor-styleButton-strikethrough {
    text-decoration: line-through;
  }
}

.md-RichEditor-activeButton {
  color: #50FF4D;
  background: #242933;

  &:hover {
    color: #08c;
  }
}

.md-RichEditor-controls-block {
  .md-RichEditor-styleButton:first-child {
    border-top-left-radius: 5px;
    border-bottom-left-radius: 5px;
  }
}

