/**
 * 文件路径: /home/ubuntu/talktalk_web/css/notebook-detail.css
 * 功能用途: 笔记详情视图、反馈评价显示、评分/翻译/词汇/语法/建议例句样式
 * 版本: 1.0
 * 说明: 从 notebook.css 拆分
 */

/* 笔记详情 */
.notebook-detail-section {
    margin-bottom: 20px;
}

.notebook-detail-section h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.notebook-detail-section h4 i {
    color: var(--primary-color);
}

.notebook-detail-text {
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    line-height: 1.6;
}

.notebook-detail-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.notebook-detail-list li {
    padding: 8px 12px;
    background: var(--bg-secondary);
    border-radius: 6px;
    margin-bottom: 6px;
    display: flex;
    gap: 10px;
}

.notebook-detail-list li:last-child {
    margin-bottom: 0;
}

.notebook-correction-original {
    text-decoration: line-through;
    color: var(--danger-color);
    opacity: 0.7;
}

.notebook-correction-arrow {
    color: var(--text-muted);
}

.notebook-correction-fixed {
    color: var(--success-color);
    font-weight: 500;
}

/* 对话中的建议提示 - 紧凑版 */
.chat-suggestion-box {
    background: var(--suggestion-bg, rgba(25, 118, 210, 0.08));
    border: 1px solid var(--suggestion-border, rgba(25, 118, 210, 0.2));
    border-radius: 10px;
    padding: 8px 12px;
    margin: 6px 0;
    font-size: 0.85em;
    max-width: 320px;
    width: fit-content;
}

.chat-suggestion-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    color: var(--primary-color, #1976D2);
    font-weight: 600;
    font-size: 0.9em;
}

.chat-suggestion-header i {
    font-size: 1em;
}

.chat-suggestion-header span {
    flex: 1;
}

.chat-suggestion-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.chat-suggestion-list.hidden {
    display: none;
}

.chat-suggestion-item {
    background: var(--card-bg, white);
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    border: 1px solid var(--border-color, transparent);
    font-size: 0.95em;
}

.chat-suggestion-item:hover {
    border-color: var(--primary-color, #1976D2);
    background: var(--hover-bg, rgba(25, 118, 210, 0.05));
    transform: translateX(2px);
}

.chat-suggestion-text {
    font-weight: 500;
    margin-bottom: 2px;
    color: var(--text-color, inherit);
}

.chat-suggestion-translation {
    font-size: 0.85em;
    color: var(--text-muted, #666);
    opacity: 0.8;
}

.chat-suggestion-difficulty {
    display: inline-block;
    font-size: 0.65em;
    padding: 1px 5px;
    border-radius: 6px;
    margin-left: 6px;
    font-weight: 600;
    text-transform: uppercase;
}

.chat-suggestion-difficulty.easy {
    background: rgba(76, 175, 80, 0.15);
    color: #4CAF50;
}

.chat-suggestion-difficulty.medium {
    background: rgba(255, 152, 0, 0.15);
    color: #FF9800;
}

.chat-suggestion-difficulty.hard {
    background: rgba(233, 30, 99, 0.15);
    color: #E91E63;
}

/* 建议内容区域 */
.chat-suggestion-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color, #1976D2) transparent;
}

.chat-suggestion-content::-webkit-scrollbar {
    width: 4px;
}

.chat-suggestion-content::-webkit-scrollbar-track {
    background: transparent;
}

.chat-suggestion-content::-webkit-scrollbar-thumb {
    background: var(--primary-color, #1976D2);
    border-radius: 2px;
    opacity: 0.5;
}

.chat-suggestion-content.hidden {
    display: none;
}

/* 各分区通用样式 */
.chat-suggestion-section,
.chat-vocabulary-section,
.chat-grammar-section {
    background: var(--card-bg, rgba(255, 255, 255, 0.5));
    border-radius: 8px;
    padding: 6px 10px;
}

.chat-suggestion-section-header {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85em;
    font-weight: 600;
    color: var(--text-muted, #666);
    margin-bottom: 5px;
}

.chat-suggestion-section-header i {
    font-size: 0.9em;
}

/* 词汇提示样式 */
.chat-vocabulary-section {
    background: var(--vocabulary-bg, rgba(156, 39, 176, 0.06));
}

.chat-vocabulary-section .chat-suggestion-section-header {
    color: var(--vocabulary-color, #9C27B0);
}

.chat-vocabulary-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.chat-vocabulary-item {
    display: flex;
    flex-direction: column;
    background: var(--card-bg, white);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.9em;
    border-left: 2px solid var(--vocabulary-color, #9C27B0);
}

.chat-vocabulary-word {
    font-weight: 600;
    color: var(--vocabulary-color, #9C27B0);
}

.chat-vocabulary-meaning {
    font-size: 0.85em;
    color: var(--text-muted, #666);
}

.chat-vocabulary-usage {
    font-size: 0.8em;
    font-style: italic;
    color: var(--text-muted, #888);
    margin-top: 2px;
}

/* 语法提示样式 */
.chat-grammar-section {
    background: var(--grammar-bg, rgba(0, 150, 136, 0.06));
}

.chat-grammar-section .chat-suggestion-section-header {
    color: var(--grammar-color, #009688);
}

.chat-grammar-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.chat-grammar-item {
    background: var(--card-bg, white);
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 0.9em;
    border-left: 2px solid var(--grammar-color, #009688);
}

.chat-grammar-pattern {
    font-weight: 600;
    color: var(--grammar-color, #009688);
    font-size: 0.95em;
}

.chat-grammar-explanation {
    font-size: 0.85em;
    color: var(--text-color, inherit);
    margin-top: 2px;
}

.chat-grammar-example {
    font-size: 0.8em;
    font-style: italic;
    color: var(--text-muted, #888);
    margin-top: 2px;
    padding-left: 8px;
    border-left: 1px solid var(--border-color, #ddd);
}

/* 对话中的反馈提示 - 紧凑版 */
.chat-feedback-box {
    background: var(--feedback-bg, rgba(56, 142, 60, 0.08));
    border: 1px solid var(--feedback-border, rgba(56, 142, 60, 0.2));
    border-radius: 10px;
    padding: 8px 12px;
    margin: 6px 0;
    font-size: 0.85em;
    max-width: 90%;
}

.chat-feedback-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.chat-feedback-title {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--success-color, #388E3C);
    font-weight: 600;
    font-size: 0.9em;
}

.chat-feedback-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.chat-feedback-section {
    background: var(--card-bg, white);
    padding: 6px 10px;
    border-radius: 6px;
}

.chat-feedback-section h5 {
    margin: 0 0 4px 0;
    font-size: 0.8em;
    color: var(--text-muted);
}

.chat-feedback-improvement {
    color: var(--success-color, #388E3C);
    font-weight: 500;
    padding: 6px 10px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: 6px;
    border-left: 2px solid var(--success-color, #4CAF50);
    font-size: 0.95em;
}

.chat-feedback-encouragement {
    font-style: italic;
    color: var(--text-muted);
    padding: 6px 10px;
    background: rgba(255, 193, 7, 0.1);
    border-radius: 6px;
    margin-top: 4px;
    font-size: 0.9em;
}

/* 折叠/展开按钮 - 紧凑版 */
.chat-assistant-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0;
    margin-left: auto;
    background: var(--bg-secondary, rgba(0,0,0,0.05));
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.7em;
    color: var(--text-muted);
    transition: all 0.15s ease;
}

.chat-assistant-toggle:hover {
    background: var(--hover-bg, rgba(25, 118, 210, 0.1));
    color: var(--primary-color);
}

.chat-assistant-toggle i {
    transition: transform 0.15s ease;
}

.chat-assistant-toggle.expanded i {
    transform: rotate(180deg);
}

/* ========================================
   用户反馈评价框样式（流式版本）
   ======================================== */

.chat-feedback-evaluation-box {
    background: var(--feedback-bg, rgba(56, 142, 60, 0.08));
    border: 1px solid var(--feedback-border, rgba(56, 142, 60, 0.2));
    border-radius: 10px;
    padding: 8px 12px;
    margin: 6px 0;
    font-size: 0.85em;
    width: 280px; /* 固定宽度，避免加载后变化 */
    /* 中文注释：右对齐，与用户消息气泡对齐 */
    align-self: flex-end;
    margin-left: auto;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.chat-feedback-evaluation-box:not(.expanded) {
    padding: 6px 12px;
}

.feedback-evaluation-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    color: var(--success-color, #388E3C);
    font-weight: 600;
    font-size: 0.9em;
    transition: margin-bottom 0.3s ease;
}

.feedback-header-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 6px;
}

.feedback-short-encouragement {
    font-size: 0.85em;
    font-style: italic;
    color: var(--text-muted);
    white-space: nowrap;
    margin-left: 6px;
}

/* 折叠时移除底部边距 */
.chat-feedback-evaluation-box:not(.expanded) .feedback-evaluation-header {
    margin-bottom: 0;
}

.feedback-evaluation-header i {
    font-size: 1em;
}

.feedback-evaluation-header span {
    /* flex: 1; Removed to prevent badge stretching */
}

.feedback-evaluation-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    /* 动画属性 */
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out, opacity 0.3s ease-out;
}

.chat-feedback-evaluation-box.expanded .feedback-evaluation-content {
    max-height: 280px; /* 限制最大高度，超出使用滚动条 */
    opacity: 1;
    overflow-y: auto; /* 展开后允许滚动 */
}

.feedback-evaluation-content::-webkit-scrollbar {
    width: 4px;
}

.feedback-evaluation-content::-webkit-scrollbar-track {
    background: transparent;
}

.feedback-evaluation-content::-webkit-scrollbar-thumb {
    background: var(--success-color, #388E3C);
    border-radius: 2px;
    opacity: 0.5;
}

/* 移除 .hidden 类依赖，使用 expanded 状态控制 */
/* .feedback-evaluation-content.hidden { display: none; } */

/* Loading状态的占位符样式 */
.feedback-loading-placeholder {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 8px 0;
}

.loading-shimmer {
    height: 14px;
    background: linear-gradient(90deg, 
        var(--card-bg, #f0f0f0) 25%, 
        var(--hover-bg, #e0e0e0) 50%, 
        var(--card-bg, #f0f0f0) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

.loading-shimmer.short {
    width: 60%;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.chat-feedback-evaluation-box.is-loading .streaming-indicator {
    color: var(--primary-color, #4CAF50);
    font-size: 0.8em;
}

/* 流式预览区域样式 */
.feedback-delta-preview {
    color: var(--text-secondary, #555);
    font-size: 14px;
    line-height: 1.6;
    padding: 10px 12px;
    white-space: pre-wrap;
    word-break: break-word;
    min-height: 24px;
    background: var(--card-bg, rgba(255, 255, 255, 0.3));
    border-radius: 6px;
    margin: 4px 0;
}

/* 打字光标闪烁动画 */
.feedback-delta-preview.typing-cursor::after {
    content: '▌';
    color: var(--primary-color, #4CAF50);
    animation: typing-blink 0.7s infinite;
    margin-left: 2px;
}

/* 有内容时光标颜色变淡 */
.feedback-delta-preview.typing-cursor.has-content::after {
    color: var(--text-muted, #999);
}

@keyframes typing-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* 评价框各分区通用样式 */
.feedback-section {
    background: var(--card-bg, rgba(255, 255, 255, 0.5));
    border-radius: 8px;
    padding: 6px 10px;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.feedback-section.visible {
    opacity: 1;
    transform: translateY(0);
}

/* streaming状态时隐藏所有分区，但visible类优先级更高 */
.chat-feedback-evaluation-box.streaming .feedback-section:not(.visible) {
    opacity: 0;
}

.feedback-section-header {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.85em;
    font-weight: 600;
    color: var(--text-muted, #666);
    margin-bottom: 5px;
}

.feedback-section-header i {
    font-size: 0.9em;
}

/* 总体评价分区 */
.feedback-score-section {
    background: var(--score-bg, rgba(255, 193, 7, 0.08));
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.feedback-encouragement {
    font-style: italic;
    color: var(--text-muted, #666);
    font-size: 0.9em;
    line-height: 1.4;
}

/* 语法纠正分区 */
.feedback-grammar-section {
    background: var(--grammar-feedback-bg, rgba(244, 67, 54, 0.06));
}

.feedback-grammar-section .feedback-section-header {
    color: var(--error-color, #F44336);
}

.feedback-corrections-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.feedback-correction-item {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 0.9em;
    padding: 4px 0;
}

.correction-original {
    text-decoration: line-through;
    color: var(--error-color, #F44336);
    background: rgba(244, 67, 54, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
}

.correction-arrow {
    color: var(--text-muted, #888);
    font-size: 0.85em;
}

.correction-fixed {
    color: var(--success-color, #4CAF50);
    background: rgba(76, 175, 80, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}

/* 词汇建议分区 */
.feedback-vocabulary-section {
    background: var(--vocabulary-feedback-bg, rgba(156, 39, 176, 0.06));
}

.feedback-vocabulary-section .feedback-section-header {
    color: var(--vocabulary-color, #9C27B0);
}

.feedback-vocabulary-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.feedback-vocabulary-item {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 0.9em;
    padding: 4px 0;
}

.vocab-word {
    font-weight: 500;
    color: var(--vocabulary-color, #9C27B0);
}

.vocab-arrow {
    color: var(--text-muted, #888);
    font-size: 0.85em;
}

.vocab-suggestion {
    color: var(--success-color, #4CAF50);
    font-weight: 500;
}

.vocab-meaning {
    font-size: 0.85em;
    color: var(--text-muted, #666);
    font-style: italic;
}

/* 改进建议分区 */
.feedback-improvement-section {
    background: var(--improvement-bg, rgba(33, 150, 243, 0.06));
}

.feedback-improvement-section .feedback-section-header {
    color: var(--info-color, #2196F3);
}

.feedback-improvement-text {
    font-size: 0.9em;
    color: var(--text-color, inherit);
    line-height: 1.4;
    padding: 4px 8px;
    background: rgba(33, 150, 243, 0.08);
    border-radius: 6px;
    border-left: 2px solid var(--info-color, #2196F3);
}

/* AI翻译分区 */
.feedback-ai-translation-section {
    background: var(--ai-translation-bg, rgba(103, 58, 183, 0.06));
}

.feedback-ai-translation-section .feedback-section-header {
    color: var(--deep-purple, #673AB7);
}

.ai-original-text {
    font-size: 0.9em;
    color: var(--text-color, inherit);
    padding: 4px 8px;
    background: rgba(103, 58, 183, 0.08);
    border-radius: 6px;
    border-left: 2px solid var(--deep-purple, #673AB7);
    margin-bottom: 4px;
    line-height: 1.4;
}

.ai-translation-text {
    font-size: 0.85em;
    color: var(--text-muted, #666);
    padding: 4px 8px;
    font-style: italic;
    line-height: 1.4;
}

/* 例句提示分区 */
.feedback-examples-section {
    background: var(--examples-bg, rgba(0, 150, 136, 0.06));
}

.feedback-examples-section .feedback-section-header {
    color: var(--teal, #009688);
}

.examples-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.example-item {
    padding: 4px 8px;
    background: rgba(0, 150, 136, 0.08);
    border-radius: 6px;
    border-left: 2px solid var(--teal, #009688);
}

.example-text {
    font-size: 0.9em;
    color: var(--text-color, inherit);
    font-weight: 500;
    line-height: 1.4;
}

.example-translation {
    font-size: 0.85em;
    color: var(--text-muted, #666);
    font-style: italic;
    margin-top: 2px;
    line-height: 1.4;
}

/* 词汇高亮样式 */
.vocab-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-bottom: 6px;
}

.vocab-highlight-item {
    background: rgba(76, 175, 80, 0.15);
    color: var(--success-color, #4CAF50);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 500;
}

/* 内容评价分区 */
.feedback-content-section {
    background: var(--content-feedback-bg, rgba(255, 152, 0, 0.06));
}

.feedback-content-section .feedback-section-header {
    color: var(--orange, #FF9800);
}

.content-feedback-text {
    font-size: 0.9em;
    color: var(--text-color, inherit);
    line-height: 1.4;
    padding: 4px 8px;
}

/* ========================================
   新版反馈板块样式
   ======================================== */

/* Translation 翻译分区 */
.feedback-translation-section {
    background: var(--ai-translation-bg, rgba(103, 58, 183, 0.06));
}

.feedback-translation-section .feedback-section-header {
    color: var(--deep-purple, #673AB7);
}

/* Error Check 错误检查分区 */
.feedback-error-check-section {
    background: var(--grammar-feedback-bg, rgba(244, 67, 54, 0.06));
}

.feedback-error-check-section .feedback-section-header {
    color: var(--error-color, #F44336);
}

/* Vocabulary Suggestion 词汇建议分区 - 卡片样式 */
.feedback-vocab-suggestion-section {
    background: var(--vocabulary-feedback-bg, rgba(156, 39, 176, 0.06));
}

.feedback-vocab-suggestion-section .feedback-section-header {
    color: var(--vocabulary-color, #9C27B0);
}

.vocab-suggestion-cards {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: thin;
    scrollbar-color: var(--vocabulary-color, #9C27B0) transparent;
}

.vocab-suggestion-cards::-webkit-scrollbar {
    height: 4px;
}

.vocab-suggestion-cards::-webkit-scrollbar-track {
    background: transparent;
}

.vocab-suggestion-cards::-webkit-scrollbar-thumb {
    background: var(--vocabulary-color, #9C27B0);
    border-radius: 2px;
    opacity: 0.5;
}

.vocab-suggestion-card {
    display: flex;
    flex-direction: column;
    background: #ffffff;
    border: 1px solid rgba(156, 39, 176, 0.15);
    border-radius: 8px;
    padding: 8px 12px;
    min-width: 140px;
    flex: 0 0 auto;
    box-shadow: 0 2px 4px rgba(156, 39, 176, 0.05);
}

.vocab-card-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.vocab-word-main {
    font-weight: 600;
    font-size: 0.95em;
    color: var(--vocabulary-color, #9C27B0);
}

.vocab-pos {
    font-size: 0.7em;
    padding: 1px 6px;
    border-radius: 4px;
    font-style: italic;
    font-weight: 500;
}

/* 词性颜色定义 - 明亮模式 */
.vocab-pos.pos-noun {
    background: #E1F5FE;
    color: #0288D1;
}

.vocab-pos.pos-verb {
    background: #E8F5E9;
    color: #388E3C;
}

.vocab-pos.pos-adj {
    background: #FFF3E0;
    color: #F57C00;
}

.vocab-pos.pos-adv {
    background: #FCE4EC;
    color: #C2185B;
}

.vocab-pos.pos-prep {
    background: #F3E5F5;
    color: #7B1FA2;
}

.vocab-pos.pos-other {
    background: rgba(156, 39, 176, 0.15);
    color: var(--vocabulary-color, #9C27B0);
}

.vocab-phonetic {
    font-size: 0.8em;
    color: var(--text-muted, #888);
    font-style: italic;
    margin-bottom: 2px;
}

.vocab-meaning-text {
    font-size: 0.85em;
    color: var(--text-color, inherit);
    line-height: 1.3;
}

/* Grammar Suggestion 语法建议分区 - 块样式 */
.feedback-grammar-suggestion-section {
    background: rgba(96, 125, 139, 0.06);
}

.feedback-grammar-suggestion-section .feedback-section-header {
    color: #607D8B;
}

.grammar-suggestion-blocks {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.grammar-suggestion-block {
    background: rgba(96, 125, 139, 0.08);
    border-left: 3px solid #607D8B;
    border-radius: 0 6px 6px 0;
    padding: 8px 12px;
}

.grammar-pattern {
    font-weight: 600;
    font-size: 0.95em;
    color: #455A64;
    margin-bottom: 4px;
}

.grammar-meaning {
    font-size: 0.85em;
    color: var(--text-color, inherit);
    margin-bottom: 3px;
}

.grammar-usage {
    font-size: 0.8em;
    color: var(--text-muted, #666);
    font-style: italic;
    line-height: 1.4;
}

/* Comment 评语分区 */
.feedback-comment-section {
    background: var(--content-feedback-bg, rgba(255, 152, 0, 0.06));
}

.feedback-comment-section .feedback-section-header {
    color: var(--orange, #FF9800);
}

/* Suggested Sentences 建议例句分区 */
.feedback-suggested-sentences-section {
    background: var(--improvement-bg, rgba(33, 150, 243, 0.06));
    /* 允许内容溢出以支持水平滚动 */
    overflow: visible;
}

.feedback-suggested-sentences-section .feedback-section-header {
    color: var(--info-color, #2196F3);
    margin-bottom: 8px;
}

.suggested-sentences-list {
    display: flex;
    flex-direction: row;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 4px 0 10px 0;
    scrollbar-width: thin;
    scrollbar-color: var(--info-color, #2196F3) transparent;
    /* 确保水平滚动正常工作 */
    flex-wrap: nowrap;
    min-width: 0;
}

.suggested-sentences-list::-webkit-scrollbar {
    height: 4px;
}

.suggested-sentences-list::-webkit-scrollbar-track {
    background: transparent;
}

.suggested-sentences-list::-webkit-scrollbar-thumb {
    background: var(--info-color, #2196F3);
    border-radius: 2px;
    opacity: 0.5;
}

.suggested-sentence-item {
    padding: 10px 14px;
    background: rgba(33, 150, 243, 0.1);
    border-radius: 10px;
    border-left: 3px solid var(--info-color, #2196F3);
    font-size: 0.9em;
    color: var(--text-color, inherit);
    line-height: 1.5;
    /* 固定宽度，不收缩不增长 */
    flex: 0 0 200px;
    min-width: 200px;
    max-width: 200px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.sentence-target {
    font-weight: 600;
    color: var(--info-color, #2196F3);
    margin-bottom: 4px;
}

.sentence-native {
    font-size: 0.9em;
    color: var(--text-muted, #666);
    font-style: italic;
}

/* 难度标识样式 */
.sentence-header {
    display: flex;
    align-items: center;
    margin-bottom: 4px;
}

.sentence-level {
    font-size: 0.75em;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sentence-level.level-beginner {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(76, 175, 80, 0.4);
}

.sentence-level.level-intermediate {
    background: rgba(255, 152, 0, 0.2);
    color: #FF9800;
    border: 1px solid rgba(255, 152, 0, 0.4);
}

.sentence-level.level-advanced {
    background: rgba(244, 67, 54, 0.2);
    color: #F44336;
    border: 1px solid rgba(244, 67, 54, 0.4);
}

/* 底部操作按钮区 */
.feedback-evaluation-actions {
    display: flex;
    justify-content: flex-end;
    /* 动画属性 */
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    transition: all 0.3s ease-out;
}

.chat-feedback-evaluation-box.expanded .feedback-evaluation-actions {
    max-height: 50px;
    opacity: 1;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--border-color, rgba(0, 0, 0, 0.1));
}

/* 移除 .visible 类依赖 */
/* .feedback-evaluation-actions.visible { opacity: 1; transform: translateY(0); } */

/* streaming状态时隐藏按钮区 */
.chat-feedback-evaluation-box.streaming .feedback-evaluation-actions {
    display: none;
}

.add-to-notebook-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    background: var(--primary-color, #1976D2);
    color: white;
    font-size: 0.85em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.add-to-notebook-btn:hover:not(:disabled) {
    background: var(--primary-dark, #1565C0);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(25, 118, 210, 0.3);
}

.add-to-notebook-btn:active:not(:disabled) {
    transform: translateY(0);
}

.add-to-notebook-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.add-to-notebook-btn.saved {
    background: var(--success-color, #4CAF50);
    cursor: default;
}

.add-to-notebook-btn i {
    font-size: 0.9em;
}

/* 语言标签 */
.notebook-language-tag {
    font-size: 0.8em;
    color: var(--text-muted);
    padding: 4px 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.notebook-detail-meta {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

/* ========================================
   按板块流式显示 - 骨架屏和动画样式
   ======================================== */

/* 骨架板块样式 */
.skeleton-section {
    opacity: 1 !important;
    transform: none !important;
}

.skeleton-section .section-content {
    min-height: 20px;
}

.skeleton-text {
    display: block;
    height: 16px;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 25%, 
        rgba(255, 255, 255, 0.2) 50%, 
        rgba(255, 255, 255, 0.1) 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s infinite;
    border-radius: 4px;
    width: 80%;
}

@keyframes skeleton-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* 流式显示中的板块 */
.section-streaming {
    opacity: 1 !important;
    transform: none !important;
}

.section-streaming .section-content {
    min-height: 20px;
}

.streaming-text {
    display: inline;
    line-height: 1.5;
    color: var(--text-color, #333);
}

/* 打字光标 */
.typing-cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: var(--primary-color, #4CAF50);
    animation: cursor-blink 0.8s infinite;
    margin-left: 2px;
    vertical-align: text-bottom;
}

@keyframes cursor-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* 完成的板块 */
.section-done {
    opacity: 1 !important;
    transform: none !important;
    animation: section-complete 0.3s ease-out;
}

@keyframes section-complete {
    from { background-color: rgba(76, 175, 80, 0.15); }
    to { background-color: transparent; }
}

/* 评分 badge 的待定状态 */
.notebook-score-badge.score-pending {
    background: var(--card-bg, rgba(255, 255, 255, 0.3));
    color: var(--text-muted, #666);
    min-width: 60px;
    text-align: center;
}

.notebook-score-badge.score-pending i {
    font-size: 0.9em;
}

/* is-loading 状态时的特殊样式 */
.chat-feedback-evaluation-box.is-loading .feedback-section {
    opacity: 1;
    transform: none;
}

.chat-feedback-evaluation-box.is-loading .add-to-notebook-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 内容文本样式 */
.section-content {
    font-size: 0.9em;
    line-height: 1.5;
    color: var(--text-color, #333);
}

/* 隐藏空板块 */
.feedback-section[style*="display: none"] {
    display: none !important;
}
