body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f9;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
}

.chat-container {
    width: 90%;
    max-width: 1500px;
    background: white;
    border-radius: 20px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    text-align: center;
}

h1 {
    font-size: 24px;
    color: #333;
    margin-bottom: 10px;
}

.chat-box {
    height: 500px;
    overflow-y: auto;
    padding: 10px;
    border: 1px solid #ddd;
    background: #fafafa;
    border-radius: 5px;
    text-align: left;
    margin-bottom: 10px;
}

.input-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
}

textarea {
    width: 98.5%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    resize: none;
    min-height: 80px; /* 4行高度 */
}

.chat-container.fullscreen-mode h1 {
    font-size: 42px;  /* 标题变大 */
    margin-top: 20px; /* 增加底部间距，进一步挤压 chat-box */
    margin-bottom: 20px;
}

.chat-container.fullscreen-mode .chat-box {
    height: calc(100vh - 100px); /* 让 chat-box 占据更大高度 */
    max-height: 80vh; /* 限制最大高度 */
}

.chat-container.fullscreen-mode textarea {
    height: 105px; /* 让输入框保持小尺寸 */
}


button {
    padding: 10px 15px;
    border: none;
    background: #007bff;
    color: white;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

button:hover {
    background: #0056b3;
}

.user-message {
    background: #007bff;  /* 蓝色背景 */
    color: white;  /* 白色字体 */
    padding: 8px;
    border-radius: 5px;
    margin: 5px 0;
    max-width: 80%;
    align-self: flex-end;
}

.ai-message {
    background: #ddd;  /* 浅灰色背景 */
    color: black;  /* 黑色字体 */
    padding: 8px;
    border-radius: 5px;
    margin: 5px 0;
    max-width: 80%;
    align-self: flex-start;
}

.error {
    color: red;
}

.chat-container {
    width: 90%;
    max-width: 1500px;
    background: white;
    border-radius: 20px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    text-align: center;
    background-size: cover;
    background-position: center;
}

.user-message, .ai-message {
    display: flex;
    align-items: center;
    padding: 8px;
    border-radius: 5px;
    margin: 5px 0;
    max-width: 80%;
    position: relative;
}


.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
}
