body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f0f0f0;
}

.chat-container {
    width: 400px;
    height: 600px;
    margin: 20px auto;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

.chat-header {
    background: #fee500;
    padding: 10px;
    text-align: center;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
}

#token-speed {
    font-size: 12px;
    color: #333;
}

.chat-messages {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
}

.message {
    margin: 10px 0;
    display: flex;
}

.user-message {
    justify-content: flex-end;
}

.llm-message {
    justify-content: flex-start;
}

.bubble {
    max-width: 70%;
    padding: 10px;
    border-radius: 10px;
    word-wrap: break-word;
}

.user-message .bubble {
    background: #fee500;
}

.llm-message .bubble {
    background: #e0e0e0;
}

.chat-input {
    margin-right: 3px;
    display: flex;
    padding: 10px;
    border-top: 1px solid #ddd;
}

#prompt {
    flex: 1;
    resize: none;
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1.15em;
}


#attach-btn {
    margin-left: 5px; /* 이미지 첨부 버튼과 입력 필드 사이에 3px 간격 추가 */
    padding: 5px 15px;
    background: #eeeeee;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

#send-btn {
    margin-left: 10px;
    padding: 5px 15px;
    background: #fee500;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* 응답 대기 중 메시지 */
.waiting-message {
    font-style: italic;
    color: #888;
    display: flex;
    align-items: center;
}
.waiting-message .spinner {
    margin-right: 5px;
}
.waiting-message.hidden {
    display: none;
}

/* 스피너 애니메이션 */
.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #888;
    border-radius: 50%;
    width: 1em;
    height: 1em;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 코드 블럭 */
.code-block {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
    margin: 5px 0;
    font-family: monospace;
    white-space: pre-wrap;
    position: relative;
    overflow-x: auto;
}
.code-block pre {
    margin: 0;
    display: inline-block;
}

/* 복사 버튼 */
.copy-button {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 3px;
    padding: 2px 5px;
    cursor: pointer;
    font-size: 12px;
    z-index: 10;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.code-block:hover .copy-button {
    opacity: 1;
}

/* <think> 블록용 (회색 표시) */
.thinking-message {
    color: #888; /* 회색 */
    margin: 5px 0;
    font-style: normal;
}
