/* Chat UI */
/*!
 * Animations from animate.css -http://daneden.me/animate
 * Version - 3.5.1
 * Licensed under the MIT license - http://opensource.org/licenses/MIT
 *
 * Copyright (c) 2016 Daniel Eden
 */
@-webkit-keyframes bouncein {
  from, 20%, 40%, 60%, 80%, to {
    -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
            animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
  }
  0% {
    opacity: 0;
    -webkit-transform: scale3d(0.3, 0.3, 0.3);
            transform: scale3d(0.3, 0.3, 0.3);
  }
  20% {
    -webkit-transform: scale3d(1.1, 1.1, 1.1);
            transform: scale3d(1.1, 1.1, 1.1);
  }
  40% {
    -webkit-transform: scale3d(0.9, 0.9, 0.9);
            transform: scale3d(0.9, 0.9, 0.9);
  }
  60% {
    opacity: 1;
    -webkit-transform: scale3d(1.03, 1.03, 1.03);
            transform: scale3d(1.03, 1.03, 1.03);
  }
  80% {
    -webkit-transform: scale3d(0.97, 0.97, 0.97);
            transform: scale3d(0.97, 0.97, 0.97);
  }
  to {
    opacity: 1;
    -webkit-transform: scale3d(1, 1, 1);
            transform: scale3d(1, 1, 1);
  }
}
@keyframes bouncein {
  from, 20%, 40%, 60%, 80%, to {
    -webkit-animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
            animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
  }
  0% {
    opacity: 0;
    -webkit-transform: scale3d(0.3, 0.3, 0.3);
            transform: scale3d(0.3, 0.3, 0.3);
  }
  20% {
    -webkit-transform: scale3d(1.1, 1.1, 1.1);
            transform: scale3d(1.1, 1.1, 1.1);
  }
  40% {
    -webkit-transform: scale3d(0.9, 0.9, 0.9);
            transform: scale3d(0.9, 0.9, 0.9);
  }
  60% {
    opacity: 1;
    -webkit-transform: scale3d(1.03, 1.03, 1.03);
            transform: scale3d(1.03, 1.03, 1.03);
  }
  80% {
    -webkit-transform: scale3d(0.97, 0.97, 0.97);
            transform: scale3d(0.97, 0.97, 0.97);
  }
  to {
    opacity: 1;
    -webkit-transform: scale3d(1, 1, 1);
            transform: scale3d(1, 1, 1);
  }
}
@-webkit-keyframes fadein {
  0% {
    opacity: 0;
  }
  35% {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes fadein {
  0% {
    opacity: 0;
  }
  35% {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.animated {
  -webkit-animation-fill-mode: both;
          animation-fill-mode: both;
}
.animated.bouncein {
  -webkit-animation-name: bouncein;
          animation-name: bouncein;
  -webkit-animation-duration: .75s;
          animation-duration: .75s;
}
.animated.fadein {
  -webkit-animation-name: fadein;
          animation-name: fadein;
  -webkit-animation-duration: 1.1s;
          animation-duration: 1.1s;
}

.chat-solid.css-icon {
  position: absolute;
  margin-left: 0.2em;
  margin-top: 0.4em;
  width: 1.5em;
  height: 1em;
  border: solid 1px currentColor;
  background-color: currentColor;
  border-radius: 0.2em;
}

.chat-solid.css-icon:before {
  content: '';
  position: absolute;
  left: 0.3em;
  top: 0.7em;
  width: 0.4em;
  height: 0.4em;
  background-color: currentColor;
  border-bottom: solid 1px currentColor;
  border-right: solid 1px currentColor;
  -webkit-transform: rotate(45deg);
          transform: rotate(45deg);
}

.close.css-icon {
  height: 26px;
  width: 20px;
}

.close.css-icon:before {
  content: '';
  position: absolute;
  top: 1em;
  width: 1.1em;
  height: 0.1em;
  background-color: currentColor;
  -webkit-transform: rotate(-45deg) translate(-2px, 4px);
          transform: rotate(-45deg) translate(-2px, 4px);
}

.close.css-icon:after {
  content: '';
  position: absolute;
  top: 1em;
  width: 1.1em;
  height: 0.1em;
  background-color: currentColor;
  -webkit-transform: rotate(45deg) translate(4px, 2px);
          transform: rotate(45deg) translate(4px, 2px);
}

.css-icon.send {
  height: 2em;
  width: 1.8em;
  position: relative;
  margin: 0 auto;
  border-radius: 10%;
}

.css-icon.send:after {
  content: "";
  display: block;
  background: currentColor;
  position: absolute;
  top: 20%;
  height: 60%;
  width: 100%;
  -webkit-clip-path: polygon(10% 0%, 90% 50%, 10% 100%, 20% 55%, 50% 50%, 20% 45%);
          clip-path: polygon(10% 0%, 90% 50%, 10% 100%, 20% 55%, 50% 50%, 20% 45%);
}

.css-icon.arrow-up {
  position: absolute;
}
.css-icon.arrow-up:before {
  content: '';
  position: absolute;
  left: 0.5em;
  top: 0.05em;
  width: 2em;
  height: 1em;
  border-top: solid 2px currentColor;
  border-right: solid 2px currentColor;
  border-radius: 0.2em;
  -webkit-transform: rotate(-45deg);
          transform: rotate(-45deg);
}

.chatbot-wrapper {
  position: relative;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 100%;
}
.chatbot-wrapper .chatbot-top {
  background: #EEEEEE;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  min-width: 100%;
  height: 40px;
  min-height: 40px;
  padding: 7px 15px;
}

.chatbot-wrapper .chatbot-top .title {
  display: flex;
  float: left;
}

.chatbot-wrapper .chatbot-top .chatbot-avatar {
  border-radius: 100%;
  height: 26px;
  margin-right: 8px;
  width: 26px;
}

.chatbot-wrapper .chatbot-top .chatbot-title.sending::after {
  content: " 正在输入中...";
}

.chatbot-wrapper .chatbot-inner {
  position: absolute;
  top: 40px;
  bottom: 58px;
  left: 0;
  right: 0;
  min-width: 100%;
  max-height: 100%;
  overflow-y: hidden;
  overflow-x: hidden;
}
.chatbot-wrapper .chatbot-inner::-webkit-scrollbar {
  background: #EEEEEE;
  border-radius: 4px;
  height: 8px;
  width: 8px;
}
.chatbot-wrapper .chatbot-inner::-webkit-scrollbar-thumb {
  background: #bbbbbb;
  border-radius: 4px;
}
.chatbot-wrapper .chatbot-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  padding: 10px;
  max-height: 100%;
  text-align: center;
}

.chatbot-wrapper .chatbot-content .contact-link {
  color: var(--link-default-color);
  text-decoration: underline;
}

.chatbot-wrapper .chatbot-content .contact-link:hover {
  text-decoration-style: dashed;
}

.chatbot-wrapper .chatbot-content .more-history:not(.disabled) {
  cursor: pointer;
  font-size: 12px;
  transition: none;
}

.chatbot-wrapper .chatbot-content .more-history.disabled {
  color: initial;
  cursor: initial;
  opacity: 0.8;
}

.chatbot-wrapper .chatbot-content .more-history.loading {
  color: #fff;
  font-size: 0;
}

.chatbot-wrapper .chatbot-content .more-history.loading::before {
  color: #999;
  content: "加载中...";
  font-size: 12px;
}

.chatbot-wrapper .chatbot-content .message-wrapper {
  text-align: left;
}

.chatbot-wrapper .chatbot-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  min-widht: 100%;
  height: 58px;
  min-height: 58px;
  padding: 12px 15px;
  border-top: 1px solid #EEE;
}
.chatbot-wrapper .info-box {
  width: 100%;
  background-color: #bbd7ff;
  padding: 1em;
}
.chatbot-wrapper .input {
  background: #EEEEEE;
  width: 100%;
  padding: 8px 40px 8px 10px;
  font-weight: 300;
  font-size: 12px;
  line-height: 1.5;
  border-radius: 0;
  border: none;
  border-bottom: 1px solid #FFF;
}
.chatbot-wrapper .input:focus {
  outline: none;
  border-bottom: 1px solid #bbbbbb;
}
.chatbot-wrapper .send {
  color: #227DFF;
  position: absolute;
  top: 11px;
  right: 27px;
  padding: 7px;
  display: block;
  float: left;
  font-size: 18px;
}
.chatbot-wrapper .send:focus {
  outline: none;
}
.chatbot-wrapper .send:hover {
  cursor: pointer;
}
.chatbot-wrapper .send .css-icon.send:after {
  border-color-left: black;
}
.chatbot-wrapper .close {
  display: none;
}
.chatbot-wrapper .message-wrapper:first-of-type {
  margin-top: 0;
}
.chatbot-wrapper .message-wrapper:last-of-type {
  margin-bottom: 10px;
}
.chatbot-wrapper .message-wrapper.me + .message-wrapper.me,
.chatbot-wrapper .message-wrapper.bot + .message-wrapper.bot {
  margin-top: 2px;
}
.chatbot-wrapper .message-wrapper {
  position: relative;
  overflow: hidden;
  width: 100%;
  margin-top: 10px;
  padding: 1px;
}
.chatbot-wrapper .text-wrapper {
  box-shadow: 0px 1px 0px 0px rgba(50, 50, 50, 0.3);
  margin: 0;
  padding: 1em;
  font-size: 13px;
  min-height: 42.66667px;
  max-width: 60%;
  position: relative;
  opacity: 0;
}
.chatbot-wrapper .me .text-wrapper {
  background: #227DFF;
  float: right;
  color: #fff;
  border-radius: 1em 1em 0 1em;
}
.chatbot-wrapper .bot .text-wrapper {
  background: #EEEEEE;
  float: left;
  color: #000;
  border-radius: 0em 1em 1em 1em;
}

.chatbot-wrapper-shortcode {
  position: relative;
  padding-bottom: 4em;
  width: 100%;
  max-height: 500px;
}

.chatbot-wrapper-livechat {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  background: #fff;
  border: 1px solid #EEEEEE;
  z-index: 19999;
  display: none;
  overflow: hidden;
}

.chatbot-wrapper-livechat,
.chatbot-wrapper-livechat *,
#chatbot-launcher-icon,
#chatbot-launcher-icon * {
  box-sizing: border-box;
}

.chatbot-wrapper-livechat .close {
  float: right;
  display: block;
}
.chatbot-wrapper-livechat .close:before, .chatbot-wrapper-livechat .close:after {
  -webkit-transition: -webkit-transform 0.3s;
  transition: -webkit-transform 0.3s;
  transition: transform 0.3s;
  transition: transform 0.3s, -webkit-transform 0.3s;
}
.chatbot-wrapper-livechat .close:hover {
  cursor: pointer;
}
.chatbot-wrapper-livechat .inner {
  height: 420px;
}

@media screen and (min-width: 500px) {
  .chatbot-wrapper-livechat {
    border-radius: 0.8em;
    box-shadow: 10px 10px 60px rgba(0, 0, 0, 0.1);
    height: 500px;
    bottom: 70px;
    left: auto;
    right: 30px;
    top: auto;
    width: 300px;
  }

  .chatbot-wrapper .chatbot-inner {
    overflow-y: auto;
  }

  .chatbot-wrapper-livechat .close:before {
    -webkit-transform: rotate(-45deg) translate(-1px, 7px) scale(0.7);
            transform: rotate(-45deg) translate(-1px, 7px) scale(0.7);
  }

  .chatbot-wrapper-livechat .close:after {
    -webkit-transform: rotate(45deg) translate(2px, 6px) scale(0.7);
            transform: rotate(45deg) translate(2px, 6px) scale(0.7);
  }
}
#chatbot-launcher-icon {
  background-color: #227DFF;
  border-radius: 100%;
  bottom: 70px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  color: #fff;
  height: 64px;
  position: fixed;
  right: 5%;
  -webkit-transition: box-shadow .15s ease-in-out;
  transition: box-shadow .15s ease-in-out;
  -webkit-transition: opacity .2s;
  transition: opacity .2s;
  opacity: 1;
  width: 64px;
  z-index: 9999;
}
#chatbot-launcher-icon .css-icon {
  font-size: 22px;
  margin: 21px 16px;
}
#chatbot-launcher-icon:hover {
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.4);
}

.chatbot-richText-wrapper {
  display: inline-block;
  margin-top: 10px;
  padding: 1px 50px;
  text-align: center;
}

.chatbot-quickReply-wrapper {
  display: inline-block;
  min-width: 20px;
  margin: 2px 4px;
  border: 1px #007acc solid;
  border-radius: 25px;
  background: white;
  cursor: pointer;
  padding: 0 12px;
}

.chatbot-quickReply {
  line-height: 26px;
  font-size: 13px;
  color: #007acc;
}
