@charset "utf-8";
/* CSS Document */

/* 右下チャットボタン */
#chatbot-toggle {
  position: fixed;
  right: 70px;
  bottom: 40px;
  z-index: 9999;
  padding: 14px 22px;
  border-radius: 999px;
  border: none;
  font-size: 15px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  background: #96C8CB;   /* Re:CENOカラー */
  color: #fff;
  letter-spacing: 0.05em;
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

#chatbot-toggle:hover {
  background: #6BB3B6;   /* 少しだけ濃く */
  box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

#chatbot-toggle:active {
  transform: scale(0.96);
  box-shadow: 0 3px 10px rgba(0,0,0,0.18);
}

/* オーバーレイ（アニメ対応） */
#chatbot-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 9998;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

/* 開いているときの状態 */
#chatbot-overlay.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* モーダル本体（ほぼ全画面） */
#chatbot-modal {
  position: absolute;
  inset: 5%;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);

  /* 開閉アニメーション用 */
  transform: scale(0.96) translateY(8px);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

/* overlay が開いたときにモーダルをふわっと出す */
#chatbot-overlay.is-open #chatbot-modal {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* ヘッダー */
#chatbot-header {
  flex: 0 0 auto;
  padding: 10px 16px;
  border-bottom: 1px solid #e3ddd5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15px;
  background: #F8F5F2;
  color: #6B5F52;
}

#chatbot-header-title {
  font-weight: 600;
  letter-spacing: 0.05em;
}

#chatbot-close {
  background: none;
  border: none;
  font-size: 26px;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  color: #6B5F52;
  transition: transform 0.15s ease, color 0.2s ease, background 0.2s ease;
  border-radius: 999px;
}

#chatbot-close:hover {
  background: rgba(107,95,82,0.08);
  color: #5D5247;
  transform: scale(1.05);
}

/* iframe エリア（チャット本体） */
#chatbot-frame {
  flex: 1 1 auto;
  width: 100%;
  height: 100%;
  border: none;
  background: #fff;
}

/* 注意書きエリア */
#chatbot-notice {
  flex: 0 0 auto;
  background: #F8F5F2;
  color: #6B5F52;
  font-size: 12px;
  line-height: 1.6;
  padding: 12px 16px;
  border-top: 1px solid #e3ddd5;
}

/* 右上の独立した × ボタン */
#chatbot-close-floating {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
  background: rgba(255,255,255,0.9);
  border: 1px solid #ddd;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 26px;
  cursor: pointer;
  display: none; /* 初期は非表示 */
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  color: #6B5F52;
  transition: background 0.2s ease, transform 0.15s ease;
}

#chatbot-close-floating:hover {
  background: rgba(240,240,240,0.95);
  transform: scale(1.05);
}

/* スマホ最適化 */
@media (max-width: 768px) {
  /* モーダルを完全全画面に */
  #chatbot-modal {
    inset: 0;
    border-radius: 0;
  }

  /* ボタンを少し大きく＆余白調整 */
  #chatbot-toggle {
    right: 10px;
    bottom: 10px;
    padding: 10px;
    font-size: .8rem;
  }

  #chatbot-header {
    padding: 12px 16px;
    font-size: 15px;
  }

  #chatbot-close {
    font-size: 30px;
    padding: 6px 10px;
  }

  #chatbot-notice {
    font-size: 13px;
    padding: 14px;
  }

  #chatbot-close-floating {
    top: 14px;
    right: 14px;
    width: 42px;
    height: 42px;
    font-size: 28px;
  }
}