.onon {
  display: block !important;
  transition-duration: 0.5s;
}
.offoff{
  display: none !important;
  transition-duration: 0.5s;
}

#pagetop {
  position: fixed;
  right: 4%;
  bottom: 18px;
  z-index: 10;
  display: none;
  width: 50px;
  height: 50px;
}

.chaticon_active #pagetop {
  display: block;
}

@media screen and (max-width:768px) {
#pagetop {
  width: 40px;
  height: 40px;
}
}

/* ↓↓↓ チャットボットUI設定 ↓↓↓ */
/* ↓↓↓ 外枠UI設定 ↓↓↓ */
.embeddedServiceSidebar.layout-docked .dockableContainer {
  width: 413px;
  top:auto;
  left: auto;
  bottom: 0;
  right: 0;
  z-index:9990;
  margin-top: 0;
  border-radius: 8px 8px 0 0;
}
/* ↓↓↓ 終了機能の非表示 ↓↓↓ */
.embeddedServiceSidebarHeader .closeButton {
  display: none;
}
.embeddedServiceSidebarHeader .fade.fade-2x {
  display: none;
}
/* ↓↓↓ ヘッダーの色調整open ↓↓↓ */
.embeddedServiceSidebarExtendedHeader {
  background-color: #e5004a;
}
/* ↓↓↓ ヘッダーの色調整close ↓↓↓ */
.embeddedServiceSidebarHeader .shortHeaderContent {
  background: #e5004a;
}
/* ↓↓↓ ヘッダーの角丸調整 ↓↓↓ */
.embeddedServiceSidebarHeader .shortHeader {
  border-radius: 0;
}
/* ↓↓↓ ヘッダーの高さ調整 ↓↓↓ */
.embeddedServiceLiveAgentStateChatHeader .content {
  height: 95px;
}
/* ↓↓↓ ヘッダー アカウントアイコンのテキスト非表示 ↓↓↓ */
.embeddedServiceLiveAgentStateChatAvatar .avatar {
  color: transparent;
}
.embeddedServiceSidebarMinimizedDefaultUI.sidebarHeader {
  border-radius: 8px;
  height: 50px;
  padding: 0;
  position: fixed;
  bottom: 76px;
  right: 4%;
  text-decoration: none;
  background-color: #aaaaaa !important;
}
/* ↓↓↓ ヘッダー アカウントアイコンのUI設定 ↓↓↓ */
.embeddedServiceLiveAgentStateChatAvatar.isLightningOutContext .agentIconColor0 {
  border: nene;
  background-color: #e5004a;
  background-image: url(/asset/img/bot/icon2_A_1.png);
  background-size: 105%;
  background-position: center;
}
/* ↓↓↓ チャット アカウントアイコンのUI設定 ↓↓↓ */
.embeddedServiceLiveAgentStateChatItem .isLightningOutContext .avatar.iconAvatar {
  color: transparent !important;
}
/* ↓↓↓ チャット ユーザー吹き出しのUI設定 ↓↓↓ */
.embeddedServiceLiveAgentStateChatPlaintextMessageDefaultUI.chasitor.plaintextContent {
  background: #e8205c;
}
/* ↓↓↓ フリーワードエリアの非表示 ↓↓↓ */
/* .embeddedServiceLiveAgentStateChat .chasitorInputWrapper {
  display: none;
} */

/* ↓↓↓ 画面端再起動ボタンUI設定 ↓↓↓ */
.embeddedServiceHelpButton, .embeddedServiceSidebarMinimizedDefaultUI.sidebarHeader {
  display: none !important;
}
.chaticon_active .embeddedServiceHelpButton, .embeddedServiceSidebarMinimizedDefaultUI.sidebarHeader {
  display: block !important;
}


.embeddedServiceHelpButton .helpButton {
  bottom: 80px !important;
  right: 4% !important;
}
.embeddedServiceSidebarMinimizedDefaultUI {
  min-width: 50px ;
  max-width: 50px ;
  width: 50px ;
  height: 50px ;
  padding: 0 ;
  border-radius: 50% !important;
  background-image: url(/asset/img/bot/bot_icon.png) ;
  background-size: 35px ;
  background-position: center ;
  background-repeat: no-repeat ;
  background-color: #aaaaaa !important;
  border-color: none !important;
  border: none !important;
  box-shadow: none  !important;
  bottom: 76px ;
  right: 4% ;
}
.embeddedServiceSidebarMinimizedDefaultUI.minimizedContainer:hover {
  background-repeat: no-repeat;
  background-color: transparent;
  border-color: transparent;
  box-shadow: none;
  opacity: 1;
}
.embeddedServiceHelpButton .helpButton .uiButton {
  min-width: 50px;
  max-width: 50px;
  width: 50px;
  height: 50px !important;
  padding: 0 !important;
  border-radius: 50% !important;
  background-image: url(../image/common/bot_icon.png) !important;
  background-size: 35px !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
  background-color: #aaaaaa !important;
  border: none !important;
  box-shadow: none !important;
}
.embeddedServiceHelpButton .helpButton .uiButton:hover::before {
  background-repeat: no-repeat !important;
  background-color: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  opacity: 1;
}

/* ↓↓↓ 画面端再起動ボタンテキスト非表示↓↓↓ */
.embeddedServiceSidebarMinimizedDefaultUI .content {
  display: none  !important;
}
.embeddedServiceHelpButton .embeddedServiceIcon::before {
  display: none;
}
.embeddedServiceHelpButton .uiButton .helpButtonLabel {
  display: none !important;
}
.embeddedServiceSidebarHeader .headerButton {
  margin-left: -31px;
}


#embeddedMessagingConversationButton {
  width:50px; height:50px;
  bottom:80px; right:4%;
  box-shadow:none;
}

#embeddedMessagingIconContainer {
  width:28px; height:28px;
  position:absolute;
  top:50%; left:50%;
  transform:translate(-50%,-50%);

  > svg{
    width:100%; height:100%;
    position:absolute;
    top:50%; left:50%;
    transform:translate(-50%,-50%);
  }

  > div{
    width:100%; height:100%;
    position:absolute;
    top:50%; left:50%;
    margin:0; padding:0;
    transform:translate(-50%,-50%);

    > div > div {
      width:100%; height:100%;
    }
  }
}

#embeddedMessagingFrame.isMinimized {
  width:50px; height:50px;
  bottom:80px; right:4%;
  opacity:0.001;
  pointer-events:none;
}
body.chaticon_active #embeddedMessagingFrame.isMinimized {
  pointer-events:auto;
}

#embedded-messaging .embeddedMessagingConversationButtonWrapper {
  visibility: hidden;
  opacity: 0;
  transition:opacity 0.4s,visibility 0.4s 0s;

  > button {
    pointer-events:none;
  }
}
body.chaticon_active #embedded-messaging .embeddedMessagingConversationButtonWrapper {
  visibility: visible;
  opacity: 1;
  transition:opacity 0.4s,visibility 0s 0s;

  > button {
    pointer-events:auto;
  }
}

#embedded-messaging .embeddedMessagingConversationButtonWrapper:has(~#embeddedMessagingFrame.isMinimized) #embeddedMessagingConversationButton {
  display: block !important;
}
#embedded-messaging .embeddedMessagingConversationButtonWrapper:has(~#embeddedMessagingFrame.isMinimized) #embeddedMessagingConversationButton #embeddedMessagingIconChat {
  display:block !important;
}





@media screen and (max-width:768px) {
  .l-footer__pagetop {
    position: fixed;
    width: 40px;
    height: 40px;
  }
  .embeddedServiceSidebar.sidebarMaximized {
    background: transparent !important;
    top: auto;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 85%;
    overflow: visible;
  }
  .embeddedServiceSidebar.layout-docked .dockableContainer {
    width: 100%;
    top:auto;
    left: auto;
    bottom: 0;
    right: 0;
    z-index:9990;
    margin-top: 0;
    border-radius: 8px 8px 0 0;
  }
  .embeddedServiceSidebar.layout-docked .dockableContainer, .embeddedServiceSidebar.layout-float .dockableContainer {
    height: 100% !important;
  }
  .embeddedServiceHelpButton .helpButton {
    bottom: 65px !important;
  }
  .embeddedServiceSidebarMinimizedDefaultUI {
    min-width: 40px;
    max-width: 40px;
    width: 40px;
    height: 40px;
    bottom: 65px;
    background-size: 26px;
  }
  .helpButton {
    width: 40px !important;
  }
  .embeddedServiceHelpButton .helpButton .uiButton {
    min-width: 40px !important;
    max-width: 40px !important;
    width: 40px !important;
    height: 40px !important;
    background-size: 26px !important;
  }
  .embeddedServiceSidebarMinimizedDefaultUI.sidebarHeader {
    border-radius: 50%;
    height: 40px;
    bottom: 71px;
    padding: 0;
    text-decoration: none;
    background-color: #aaaaaa !important;
  }
  /* ↓↓↓ フリーワードエリア入力時のピンチアウト防止 ↓↓↓ */
  .embeddedServiceLiveAgentStateChatInputFooter .chasitorText {
    font-size: 1em !important;
  }
}






/* 新バージョン用CSS　Salesforce Summer '20 リリースノート */
button.closeButton[embeddedService-chatHeader_chatHeader] {
  display: none;
}
.sidebarHeader[embeddedService-chatHeader_chatHeader] {
justify-content: flex-end;
flex-direction: row-reverse;
}
h2[embeddedService-chatHeader_chatHeader] {
  display: flex;
  justify-content: center;
}
button:hover[embeddedService-chatHeader_chatHeader]:before {
  content: " ";
  position: absolute;
  top: 9px;
  width: 0;
  height: 0;
  background-color: transparent;
  opacity: 0;
  border-radius: 0;
  box-sizing: border-box;
  pointer-events: none
}



@media screen and (max-width:768px) {
  #embeddedMessagingIconContainer {
    width: 20px;
    height: 20px;
  }
  #embeddedMessagingConversationButton {
    width: 40px;
    height: 40px;
    bottom: 66px;
    right: 4%;
  }
}