/* =================================================================
   chatbot.css — AI 상담 챗봇 위젯 (#hitech-ai-chatbot, 화면 오른쪽 아래)
   - 불러오는 곳: index.php 만 ($page_styles)
   - 예전 HTML 인라인 style="" 속성을 그대로 옮겨온 것
   - id 선택자(#...)를 쓰는 이유: 인라인 스타일이던 때처럼
     style.css 등 다른 규칙보다 항상 우선 적용되게 하려고
   - 동작(열기/닫기, 메시지 추가)은 assets/js/chatbot.js
   ================================================================= */

/* 위젯 전체 위치 (오른쪽 아래 고정) */
#hitech-ai-chatbot {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999999;
    font-family: 'Malgun Gothic', sans-serif;
}

/* 챗봇 열기 버튼 (파란 동그라미) */
#chat-toggle-trigger {
    background-color: #0056b3;
    color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    font-size: 26px;
    outline: none;
}

/* 대화 창 — 기본은 숨김, chatbot.js가 style.display 값을 바꿔 열고 닫음 */
#chat-popup-window {
    display: none;
    width: 360px;
    height: 480px;
    background-color: white !important;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.2);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    position: absolute;
    bottom: 75px;
    right: 0;
}

/* 대화 창 제목줄 */
#chat-header-title {
    background-color: #0056b3;
    color: white;
    padding: 16px;
    font-weight: bold;
    font-size: 14px;
    letter-spacing: -0.5px;
}

/* 대화 내용 영역 (스크롤) */
#chat-logs-area {
    height: 350px;
    padding: 15px;
    overflow-y: auto;
    font-size: 13px;
    background-color: #f8fafc;
    line-height: 1.5;
}

/* 첫 인사 말풍선 */
#chat-welcome-msg {
    background: #e2e8f0;
    color: #1a202c;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 12px;
    display: inline-block;
    max-width: 85%;
}

/* 입력줄 · 입력칸 · 전송 버튼 */
#hitech-ai-chatbot .chat-input-row {
    border-top: 1px solid #edf2f7;
    padding: 10px;
    display: flex;
    background: #ffffff;
}

#chat-user-input {
    flex: 1;
    border: 1px solid #cbd5e0;
    padding: 10px;
    border-radius: 6px;
    outline: none;
    font-size: 13px;
}

#chat-send-trigger {
    background: #0056b3;
    color: white;
    border: none;
    padding: 0 16px;
    margin-left: 6px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: bold;
}

/* ── chatbot.js가 만들어 넣는 메시지 말풍선 (사용자 / AI / 응답 대기 / 오류) ── */
#chat-logs-area .chat-msg {
    margin-bottom: 12px;
}

#chat-logs-area .chat-msg-user {
    text-align: right;
}

#chat-logs-area .chat-bubble {
    padding: 10px 14px;
    border-radius: 8px;
    display: inline-block;
}

#chat-logs-area .chat-bubble-user {
    background: #0056b3;
    color: white;
    max-width: 85%;
    text-align: left;
}

#chat-logs-area .chat-bubble-ai {
    background: #e2e8f0;
    color: #1a202c;
    max-width: 85%;
}

#chat-logs-area .chat-bubble-loading {
    background: #e2e8f0;
    color: #4a5568;
}

#chat-logs-area .chat-bubble-error {
    background: #fed7d7;
    color: #9b2c2c;
}
