/* chat_widget
====================================================================================================================================== */
#chat_widget {
  position: fixed;
  bottom: 0;
  right: 15px;
  z-index: 2147483647;
  width: 390px;
  background-color: #fff;
  border-radius: 30px 30px 0 0;
  overflow: hidden;
  font-size: 0.9rem;
  line-height: 1.8;
  transition: .4s ease-out;
  translate: 0 100%; }
  @media screen and (min-width: 1200px) {
    #chat_widget {
      width: 410px; } }
  #chat_widget.open {
    translate: 0;
    box-shadow: 0 0 200px rgba(0, 0, 0, 0.15); }
  #chat_widget.minimize {
    translate: 0 calc(100% - 65px); }
  #chat_widget.maximize #chat_widget_body {
    height: calc(100vh - 65px - 5px); }
  #chat_widget p,
  #chat_widget ul {
    margin: 0;
    padding: 0; }
  #chat_widget ul {
    list-style-type: none; }

.cms-ready #chat_widget.maximize #chat_widget_body {
  height: calc(100vh - 46px - 65px - 5px); }

#chat_widget_header {
  background-color: #fff;
  color: #111;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 65px;
  padding: 0 20px; }
  #chat_widget_header .widget_title {
    text-align: left;
    line-height: 1.3; }
  #chat_widget_header .chat_buttons {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 15px; }
    #chat_widget_header .chat_buttons .button_wrap {
      cursor: pointer;
      width: 24px;
      transition: .2s; }
      #chat_widget_header .chat_buttons .button_wrap img {
        width: 100%; }

@media (hover: hover) {
  #chat_widget_header .chat_buttons .button_wrap:hover {
    opacity: 0.5; } }
#button_chat_open a:focus {
  outline-color: #000 !important; }

#first_select_menu {
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: 9999;
  width: 100%;
  border-top: 1px solid #d9d9d9;
  background-color: #fff;
  transition: .5s; }
  #first_select_menu.closed {
    translate: 0 100%; }
    #first_select_menu.closed .menu_open_close a {
      background-image: url(../images/icon/chat_menu_open.svg); }
  #first_select_menu .menu_open_close {
    position: absolute;
    bottom: 100%;
    left: 0; }
    #first_select_menu .menu_open_close a {
      display: block;
      text-decoration: none;
      font-size: 0.8em;
      font-weight: normal;
      line-height: 1;
      color: #fff;
      padding: 12px 20px 12px 38px;
      border-top-right-radius: 8px;
      background: #0A67BF url(../images/icon/chat_menu_close.svg) no-repeat left 12px center;
      background-size: 20px auto; }
  #first_select_menu ul {
    display: grid;
    grid-template-columns: repeat(2, 1fr); }
    #first_select_menu ul li {
      border-right: 1px solid #d9d9d9;
      border-bottom: 1px solid #d9d9d9; }
      #first_select_menu ul li:nth-child(even) {
        border-right: none; }
      #first_select_menu ul li a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        text-decoration: none;
        color: #0A67BF;
        padding: 10px; }
      #first_select_menu ul li .icon {
        width: 46px; }
        #first_select_menu ul li .icon img {
          width: 100%; }
      #first_select_menu ul li .text_area {
        width: calc(100% - 46px - 10px);
        font-weight: bold;
        line-height: 1.5; }
        #first_select_menu ul li .text_area p {
          margin-bottom: 0; }
        #first_select_menu ul li .text_area .small_text {
          font-size: 0.6em; }

@media (hover: hover) {
  #first_select_menu .menu_open_close a:hover {
    opacity: 0.7; }
  #first_select_menu ul li a:hover {
    opacity: 0.7; } }
#chat_widget_body {
  background-color: #fff;
  padding: 0 20px;
  height: 485px;
  overflow-x: hidden;
  overflow-y: auto;
  transition: .4s ease-out; }
  #chat_widget_body .chat_body_inner {
    padding-bottom: 90px; }
  #chat_widget_body .chat_log {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 25px; }
    #chat_widget_body .chat_log:last-of-type {
      margin-bottom: 0; }
    #chat_widget_body .chat_log .text_area {
      width: calc(100% - 44px - 11px); }
    #chat_widget_body .chat_log .fukidashi {
      border-radius: 10px;
      position: relative;
      padding: 13px 15px;
      background-color: #f2f5f5; }
      #chat_widget_body .chat_log .fukidashi.bg_blue {
        background-color: #DEF0FA; }
      #chat_widget_body .chat_log .fukidashi:before {
        content: "";
        position: absolute;
        display: block;
        right: 100%;
        top: calc(22px - 5px);
        width: calc(tan(60deg) * 9px / 2);
        height: 9px;
        clip-path: polygon(100% 0, 100% 100%, 0 50%);
        background-color: #f2f5f5; }
      #chat_widget_body .chat_log .fukidashi p {
        margin-bottom: 0; }
    #chat_widget_body .chat_log .choices_list.link_list li a,
    #chat_widget_body .chat_log .choices_list.link_list li.button_continue,
    #chat_widget_body .chat_log .choices_list.link_list li.button_chat_end,
    #chat_widget_body .chat_log .alternative_list li a,
    #chat_widget_body .chat_log .alternative_list li.button_continue,
    #chat_widget_body .chat_log .alternative_list li.button_chat_end {
      display: block;
      padding: 9px 13px;
      text-decoration: none;
      color: #111; }
      #chat_widget_body .chat_log .choices_list.link_list li a[target="_blank"],
      #chat_widget_body .chat_log .choices_list.link_list li.button_continue[target="_blank"],
      #chat_widget_body .chat_log .choices_list.link_list li.button_chat_end[target="_blank"],
      #chat_widget_body .chat_log .alternative_list li a[target="_blank"],
      #chat_widget_body .chat_log .alternative_list li.button_continue[target="_blank"],
      #chat_widget_body .chat_log .alternative_list li.button_chat_end[target="_blank"] {
        padding-right: 27px;
        background: url(../images/icon/i_outlink.svg) no-repeat right 14px center;
        background-size: 12px auto; }
    #chat_widget_body .chat_log .choices_list li,
    #chat_widget_body .chat_log .alternative_list li {
      font-weight: bold;
      background-color: #fff;
      border-radius: 6px;
      padding: 9px 13px;
      margin-bottom: 10px;
      color: #111;
      cursor: pointer; }
      #chat_widget_body .chat_log .choices_list li:last-child,
      #chat_widget_body .chat_log .alternative_list li:last-child {
        margin-bottom: 0; }
      #chat_widget_body .chat_log .choices_list li.bg_blue,
      #chat_widget_body .chat_log .alternative_list li.bg_blue {
        color: #fff !important;
        background-color: #0A67BF; }
      #chat_widget_body .chat_log .choices_list li.bg_gray,
      #chat_widget_body .chat_log .alternative_list li.bg_gray {
        color: #fff !important;
        background-color: #666; }
      #chat_widget_body .chat_log .choices_list li.other_link,
      #chat_widget_body .chat_log .alternative_list li.other_link {
        background: none !important;
        text-align: right;
        padding: 0.3rem 0 0 !important;
        font-size: 0.85rem !important;
        text-decoration: underline;
        color: #0A67BF;
        margin-bottom: 0 !important; }
      #chat_widget_body .chat_log .choices_list li:has(a),
      #chat_widget_body .chat_log .alternative_list li:has(a) {
        padding: 0; }
      #chat_widget_body .chat_log .choices_list li a,
      #chat_widget_body .chat_log .alternative_list li a {
        transition: none; }
    #chat_widget_body .chat_log .choices_list {
      margin-top: 0.9em; }
      #chat_widget_body .chat_log .choices_list.link_list li {
        padding: 0; }
    #chat_widget_body .chat_log .no_choices {
      font-weight: bold;
      text-align: right;
      margin-top: 10px; }
    #chat_widget_body .chat_log .confirm_area {
      margin-top: 15px; }
    #chat_widget_body .chat_log .alternative_list {
      display: flex;
      justify-content: flex-start;
      gap: 10px;
      margin-top: 0.5rem; }
      #chat_widget_body .chat_log .alternative_list li {
        margin-bottom: 0 !important; }
      #chat_widget_body .chat_log .alternative_list.vertical {
        display: block;
        max-width: 12em; }
        #chat_widget_body .chat_log .alternative_list.vertical.wide {
          max-width: initial; }
        #chat_widget_body .chat_log .alternative_list.vertical li + li {
          margin: 10px 0 0; }
    #chat_widget_body .chat_log.talk_bot .icon {
      width: 44px;
      aspect-ratio: 1;
      border: 1px solid #d9d9d9;
      border-radius: 50%;
      overflow: hidden; }
      #chat_widget_body .chat_log.talk_bot .icon img {
        width: 100%;
        height: 100%;
        object-fit: cover; }
    #chat_widget_body .chat_log.talk_bot .stamp {
      width: min(200px, 100%); }
      #chat_widget_body .chat_log.talk_bot .stamp img {
        width: 100%; }
    #chat_widget_body .chat_log.talk_user {
      justify-content: flex-end; }
      #chat_widget_body .chat_log.talk_user .text_area {
        width: fit-content; }
      #chat_widget_body .chat_log.talk_user .fukidashi {
        background-color: #1D72C2;
        color: #fff;
        font-weight: bold; }
        #chat_widget_body .chat_log.talk_user .fukidashi:before {
          right: auto;
          left: calc(100% - 1px);
          top: 50%;
          translate: 0 -50%;
          clip-path: polygon(0 0, 100% 50%, 0 100%);
          background-color: #1D72C2; }

@media (hover: hover) {
  #chat_widget_body .chat_log .choices_list li:hover {
    opacity: 0.7; }
  #chat_widget_body .chat_log .alternative_list:has(.bg_gray) li a:hover {
    opacity: 0.7; } }
/* button_chat_open
====================================================================================================================================== */
#button_chat_open {
  position: fixed;
  bottom: 12px;
  right: 3.7rem;
  z-index: 10000; }
  #button_chat_open a {
    display: flex;
    align-items: center;
    gap: 12px;
    background-color: #1D72C2;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: bold;
    text-align: left;
    line-height: 1.4;
    padding: 0.4rem;
    padding-right: 1.4rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
    text-decoration: none;
    color: #fff;
    position: relative;
    transition: .2s; }
    #button_chat_open a .charactor {
      display: block;
      width: 2.2rem;
      border-radius: 50%;
      overflow: hidden; }
      #button_chat_open a .charactor img {
        width: 100%; }

@media (hover: hover) {
  #button_chat_open a:hover {
    opacity: 0.7; } }
@media screen and (max-width: 540px) {
  /* chat_widget
  ====================================================================================================================================== */
  #chat_widget {
    right: 0;
    width: 100%; }

  #chat_widget_header .chat_buttons {
    gap: 16px; }

  #chat_widget_body {
    height: 440px; } }
