﻿/* AI Chat Core Styles */

/* 基本樣式 */
.alignleft {
    float: left;
}

.alignright {
    float: right;
}

/*.card {
    background: #fff;
    box-shadow: 0 6px 10px rgba(0,0,0,.08), 0 0 6px rgba(0,0,0,.05);
    transition: .3s transform cubic-bezier(.155,1.105,.295,1.12),.3s box-shadow,.3s -webkit-transform cubic-bezier(.155,1.105,.295,1.12);
    cursor: pointer;
}

.card:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(0,0,0,.12), 0 4px 8px rgba(0,0,0,.06);
}*/

.fontFree {
    font-size: 0.9em;
    color: white;
}

.multi-ellipsis {
    display: -webkit-box; /* 彈性盒模型 */
    -webkit-box-orient: vertical; /* 垂直方向 */
    -webkit-line-clamp: 4; /* 限制行數 */
    line-clamp: 4; /* 標準屬性 */
    overflow: hidden; /* 超出隱藏 */
}

/* AI 聊天介面樣式 */
.ai-chat-container {
    position: fixed;
    bottom: 85px;
    right: 20px;
    width: 400px;
    height: 500px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    display: none;
    flex-direction:column;
}

.ai-chat-header {
    background: #007bff;
    color: white;
    padding: 15px;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ai-chat-body {
    flex-grow: 1;
    overflow-y: auto;
    padding: 10px;
}

.ai-chat-input {
    padding: 15px;
    border-top: 1px solid #eee;
}

.ai-message {
    margin-bottom: 10px;
    list-style: none;
}

.message-content {
    padding: 10px;
    border-radius: 8px;
    margin: 5px 0;
    word-wrap: break-word;
}

.ai-toggle-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1001;
}

.ai-toggle-btn:hover {
    background: #0056b3;
}

.quick-recommend-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.quick-recommend-btn {
    padding: 5px 10px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 15px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.quick-recommend-btn:hover {
    background: #e9ecef;
    border-color: #007bff;
}

/* 檔案上傳區域 */
.file-upload-area {
    margin-bottom: 10px;
    padding: 10px;
    border: 2px dashed #ddd;
    border-radius: 5px;
    background: #f9f9f9;
}

.file-preview {
    margin-top: 10px;
}

.file-item {
    display: flex;
    align-items: center;
    padding: 5px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 3px;
    margin-bottom: 5px;
}

.file-name {
    flex: 1;
    font-size: 12px;
}

.file-size {
    font-size: 11px;
    color: #666;
    margin: 0 10px;
}

.btn-remove-file {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    cursor: pointer;
}

.btn-remove-file:hover {
    background: #c82333;
}

/* 動畫效果 */
.ai-chat-container.show {
    animation: slideInUp 0.3s ease-out;
}

.ai-chat-container.hide {
    animation: slideOutDown 0.3s ease-in;
}

@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideOutDown {
    from {
        transform: translateY(0);
        opacity: 1;
    }
    to {
        transform: translateY(100%);
        opacity: 0;
    }
}

