/* 챗봇 위젯 스타일 */

/* 챗봇 버튼 */
.chatbot-button {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: linear-gradient(to bottom right, var(--chatbot-primary-color, #2563eb), var(--chatbot-hover-color, #1d4ed8));
  border: none;
  cursor: pointer;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  transition: all 0.3s ease;
  transform-origin: center;
}

.chatbot-button:hover {
  background: linear-gradient(to bottom right, var(--chatbot-hover-color, #1d4ed8), var(--chatbot-primary-color, #1e40af));
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2), 0 4px 6px -4px rgba(0, 0, 0, 0.2);
}

.chatbot-button.hidden {
  transform: scale(0);
  opacity: 0;
  pointer-events: none;
}

.chatbot-button-icon {
  width: 1.5rem;
  height: 1.5rem;
  color: white;
}

/* 챗봇 창 (데스크톱) */
.chatbot-window {
  position: fixed;
  bottom: 0;
  right: 0;
  width: 418px;  /* 380px에서 10% 증가 (380 * 1.1 = 418px) */
  height: 100vh;
  max-height: 100vh;
  background: white;
  border-radius: 1rem 0 0 0;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 1001;
  transform-origin: bottom right;
  transition: all 0.3s ease;
}

.chatbot-window.hidden {
  transform: scale(0);
  opacity: 0;
  pointer-events: none;
}

/* 챗봇 헤더 */
.chatbot-header {
  background: linear-gradient(to right, var(--chatbot-primary-color, #2563eb), var(--chatbot-hover-color, #1d4ed8));
  padding: 0.7rem;  /* 1rem에서 30% 감소 (1rem * 0.7 = 0.7rem) */
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.chatbot-header-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.chatbot-header-icon {
  width: 1.75rem;  /* 2.5rem에서 30% 감소 (2.5rem * 0.7 = 1.75rem) */
  height: 1.75rem;  /* 2.5rem에서 30% 감소 */
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.chatbot-header-icon svg {
  width: 0.9rem;  /* 1.25rem에서 약 28% 감소 (더 작게 조정) */
  height: 0.9rem;  /* 1.25rem에서 약 28% 감소 */
  color: white;
}

.chatbot-header-text h3 {
  color: white;
  font-size: 1rem;
  font-weight: 500;
  margin: 0;
  line-height: 1.2;
}

.chatbot-header-text p {
  color: #bfdbfe;
  font-size: 0.75rem;
  margin: 0;
  line-height: 1.2;
}

.chatbot-header-buttons {
  display: flex;
  gap: 0.5rem;
}

.chatbot-close-button {
  width: 2rem;
  height: 2rem;
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.25rem;
  transition: background-color 0.2s;
}

.chatbot-close-button:hover {
  background: rgba(255, 255, 255, 0.2);
}

.chatbot-close-button svg {
  width: 1rem;
  height: 1rem;
}

/* 챗봇 iframe 영역 */
.chatbot-iframe-container {
  flex: 1;
  overflow: hidden;
  background: #f8fafc;
}

.chatbot-iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* 모바일 전체화면 버전 */
.chatbot-window-mobile {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: white;
  z-index: 1002;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform 0.3s ease;
  transform: translateY(100%);
}

.chatbot-window-mobile.open {
  transform: translateY(0);
}

.chatbot-window-mobile .chatbot-header {
  flex-shrink: 0;
}

.chatbot-window-mobile .chatbot-iframe-container {
  flex: 1;
  overflow: hidden;
}

/* 모바일에서 데스크톱 버전 숨김 */
@media (max-width: 767px) {
  .chatbot-window {
    display: none;
  }
}

/* 데스크톱에서 모바일 버전 숨김 */
@media (min-width: 768px) {
  .chatbot-window-mobile {
    display: none;
  }
}

