/* 报告模态框样式 */
.report-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow: auto;
}

.report-modal .modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 0;
    width: 80%;
    max-width: 900px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.report-modal .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid #e0e0e0;
}

.report-modal .modal-header h3 {
    margin: 0;
    font-size: 1.4rem;
    color: #333;
}

.report-modal .close-modal {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.report-modal .modal-body {
    padding: 0;
    overflow: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.report-modal .report-content {
    flex: 1;
    padding: 24px;
    overflow: auto;
}

.report-modal .modal-footer {
    display: flex;
    justify-content: flex-end;
    padding: 16px 24px;
    border-top: 1px solid #e0e0e0;
    gap: 12px;
}

.report-modal button {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.report-modal .copy-report {
    background-color: #f0f0f0;
    color: #333;
}

.report-modal .download-report {
    background-color: #4caf50;
    color: white;
}

.report-modal button:hover {
    opacity: 0.9;
}

.report-modal button i {
    font-size: 18px;
}

/* Markdown内容样式 */
.markdown-body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    line-height: 1.6;
    word-wrap: break-word;
    color: #24292e;
}

.markdown-body h1, 
.markdown-body h2 {
    margin-top: 24px;
    margin-bottom: 16px;
    font-weight: 600;
    line-height: 1.25;
}

.markdown-body h1 {
    padding-bottom: 0.3em;
    font-size: 2em;
    border-bottom: 1px solid #eaecef;
}

.markdown-body h2 {
    padding-bottom: 0.3em;
    font-size: 1.5em;
    border-bottom: 1px solid #eaecef;
}

.markdown-body p {
    margin-top: 0;
    margin-bottom: 16px;
}

.markdown-body code {
    padding: 0.2em 0.4em;
    margin: 0;
    font-size: 85%;
    background-color: rgba(27, 31, 35, 0.05);
    border-radius: 3px;
}

.markdown-body pre {
    padding: 16px;
    overflow: auto;
    font-size: 85%;
    line-height: 1.45;
    background-color: #f6f8fa;
    border-radius: 3px;
}

/* 修复表格偶数行样式 */
.markdown-body table tr:nth-child(2n) {
    background-color: #f6f8fa; /* 浅灰色背景 */
    color: #24292e !important; /* 强制使用深色文字 */
}

/* 确保所有表格文字可见 */
.markdown-body table tr {
    color: #24292e !important;
}

/* 表格单元格样式微调 */
.markdown-body table th,
.markdown-body table td {
    padding: 8px 12px;
    border: 1px solid #dfe2e5;
    color: inherit !important; /* 继承行的文字颜色 */
}

/* 表头样式 */
.markdown-body table th {
    background-color: #f6f8fa;
    font-weight: 600;
    color: #24292e !important;
}

.markdown-body blockquote {
    padding: 0 1em;
    color: #6a737d;
    border-left: 0.25em solid #dfe2e5;
    margin: 0 0 16px 0;
}

/* 生成报告按钮样式 */
.generate-report-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    background-color: #2196f3;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.generate-report-btn:hover {
    background-color: #0d8af0;
}

.generate-report-btn i {
    font-size: 18px;
}


/* 汇总报告按钮的专门样式 */

#generate-summary-report {
    /* 基本样式 */
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    padding: 10px 16px;
    background-color: #2196f3;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    
    /* 消除可能导致整区域交互的特性 */
    transition: none;
    position: relative;
    z-index: 1;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* 确保只有按钮区域可交互，不设置悬浮效果 */
#generate-summary-report:hover {
    background-color: #2196f3;
}

/* 禁用状态样式 */
#generate-summary-report:disabled {
    background-color: #cccccc;
    color: #666666;
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: none;
}

/* 图标样式 */
#generate-summary-report i {
    font-size: 18px;
}

/* 明确分隔按钮与其他元素 */
.overview .experiment-intro {
    margin-bottom: 20px;
}

/* 汇总报告模态框样式 */
.summary-report-modal .modal-content {
    width: 90%;
    max-width: 1000px;
}

.summary-report-modal .report-content {
    max-height: 70vh;
    overflow: auto;
}



/* 修复表格偶数行文字不可见问题 */
.markdown-body table tr,
.markdown-body table tr:nth-child(even),
.markdown-body table tr:nth-child(odd) {
    color: #24292e !important; /* 强制使用深色文字 */
}

.markdown-body table tr:nth-child(even) {
    background-color: #f6f8fa !important; /* 浅灰色背景 */
}

.markdown-body table td,
.markdown-body table th {
    color: #24292e !important; /* 确保单元格文字颜色 */
    border: 1px solid #dfe2e5;
    padding: 8px 12px;
}

/* 确保表格内容可见 */
.modal-body .markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    color: #24292e;
}

.modal-body .markdown-body th {
    background-color: #f0f0f0;
    padding: 8px;
    text-align: left;
    border: 1px solid #dfe2e5;
    font-weight: 600;
}

/* 参考ai-report.css的表格样式 */
.modal-body .markdown-body tr:nth-child(even) {
    background-color: rgba(0, 0, 0, 0.02);
}

/* 加载中样式 */
.loading-report {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px;
    color: #666;
    text-align: center;
}

.loading-report:before {
    content: '';
    width: 40px;
    height: 40px;
    margin-bottom: 20px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #2196f3;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error-message {
    padding: 20px;
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 20px 0;
}

/* 强制修复表格样式 */
.markdown-body table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 16px;
    color: #24292e !important;
}

.markdown-body table tr {
    color: #24292e !important;
    background-color: #ffffff !important;
}

.markdown-body table tr:nth-child(2n) {
    background-color: #f6f8fa !important;
    color: #24292e !important;
}

.markdown-body table th,
.markdown-body table td {
    padding: 8px 12px;
    border: 1px solid #dfe2e5;
    color: #24292e !important;
}

.markdown-body table th {
    background-color: #f0f0f0 !important;
    font-weight: 600;
}

/* 确保所有文字颜色正确 */
.modal-body .markdown-body {
    color: #24292e !important;
}

/* 深色主题报告样式 */

/* 报告模态框样式调整 */
.report-modal .modal-content {
    background-color: #1a2131;
    color: #e4e6eb;
    border: 1px solid #394151;
}

.report-modal .modal-header {
    background-color: #252f3f;
    border-bottom: 1px solid #394151;
}

.report-modal .modal-header h3 {
    color: #e4e6eb;
}

.report-modal .close-modal {
    color: #e4e6eb;
}

.report-modal .modal-footer {
    border-top: 1px solid #394151;
}

.report-modal .copy-report {
    background-color: #323c4e;
    color: #e4e6eb;
}

.report-modal .download-report {
    background-color: #4caf50;
    color: white;
}

/* 汇总报告模态框样式 */
.summary-report-modal .modal-content {
    background-color: #1a2131;
    color: #e4e6eb;
}

/* Markdown内容深色主题 */
.markdown-body {
    color: #e4e6eb !important;
    background-color: transparent !important;
}

.markdown-body h1, 
.markdown-body h2,
.markdown-body h3,
.markdown-body h4 {
    color: #64b5f6 !important;
    border-bottom-color: #394151 !important;
}

.markdown-body p,
.markdown-body li,
.markdown-body ul,
.markdown-body ol {
    color: #e4e6eb !important;
}

.markdown-body strong {
    color: #ffeb3b !important;
}

.markdown-body a {
    color: #64b5f6 !important;
}

.markdown-body blockquote {
    color: #a0a8b7 !important;
    border-left-color: #394151 !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
}

.markdown-body code {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: #e4e6eb !important;
}

.markdown-body pre {
    background-color: #252f3f !important;
    border: 1px solid #394151 !important;
}

/* 表格深色主题样式 - 确保所有文字清晰可见 */
.markdown-body table {
    border-collapse: collapse;
    width: 100%;
    margin: 15px 0;
}

.markdown-body table tr {
    background-color: #1f283a !important;
    color: #e4e6eb !important;
}

.markdown-body table tr:nth-child(2n) {
    background-color: #252f3f !important;
    color: #e4e6eb !important;
}

.markdown-body table th,
.markdown-body table td {
    padding: 8px 12px;
    border: 1px solid #394151 !important;
    color: #e4e6eb !important;
}

.markdown-body table th {
    background-color: #323c4e !important;
    color: #e4e6eb !important;
    font-weight: 600;
}

/* 修复表格内容在深色主题下可见 */
.modal-body .markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.modal-body .markdown-body th {
    background-color: #323c4e !important;
    padding: 8px;
    text-align: left;
    border: 1px solid #394151 !important;
    font-weight: 600;
    color: #e4e6eb !important;
}

.modal-body .markdown-body td {
    color: #e4e6eb !important;
    padding: 8px;
    border: 1px solid #394151 !important;
}

.modal-body .markdown-body tr:nth-child(odd) {
    background-color: #1f283a !important;
}

.modal-body .markdown-body tr:nth-child(even) {
    background-color: #252f3f !important;
}

/* 加载状态样式调整 */
.loading-report {
    color: #a0a8b7;
}

.loading-report:before {
    border: 4px solid #252f3f;
    border-top: 4px solid #64b5f6;
}

.error-message {
    color: #f48fb1;
    background-color: rgba(244, 67, 54, 0.1);
    border: 1px solid rgba(244, 67, 54, 0.3);
}

/* 汇总报告按钮样式 */
#generate-summary-report {
    background-color: #2196f3;
    color: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    padding: 10px 16px;
    border-radius: 4px;
    margin-top: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    position: relative;
    z-index: 1;
}

#generate-summary-report:hover {
    background-color: #0d8af0;
}

#generate-summary-report:disabled {
    background-color: #394151;
    color: #a0a8b7;
    cursor: not-allowed;
    opacity: 0.7;
    box-shadow: none;
}

#generate-summary-report i {
    font-size: 18px;
}

/* 改进生成报告按钮样式 */
.generate-report-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 14px;
    background-color: #2196f3;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.generate-report-btn:hover {
    background-color: #0d8af0;
}

.generate-report-btn:disabled {
    background-color: #394151;
    color: #a0a8b7;
    cursor: not-allowed;
    opacity: 0.7;
}

.generate-report-btn i {
    font-size: 18px;
}

\unityprograms\labp_ht_electron\src\renderer\styles\report-styles.css */

/* 添加数据导出按钮样式 */
.export-data-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background-color: #0d8af0;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
    margin-top: 20px;
}

.export-data-btn:hover {
    background-color: #0a6fc0;
}

.export-data-btn i {
    font-size: 18px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #ddd;
}
/* 美化报告按钮样式 */
.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 共享按钮基础样式 */
.modal-footer button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    min-width: 140px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.modal-footer button i {
    font-size: 18px;
}

/* 复制报告按钮 */
.copy-report {
    background-color: #3a4255;
    color: #e4e6eb;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.copy-report:hover {
    background-color: #4a536a;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.copy-report:active {
    transform: translateY(0);
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
}

/* 下载报告按钮 */
.download-report {
    background-color: #2196f3;
    color: white;
}

.download-report:hover {
    background-color: #0d8bf2;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.download-report:active {
    transform: translateY(0);
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
}

/* 按钮图标动画效果 */
.copy-report:hover i {
    animation: pulse 1s infinite;
}

.download-report:hover i {
    animation: bounce 1s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* 适配深色主题 */
.summary-report-modal .modal-footer button {
    position: relative;
    overflow: hidden;
}

.summary-report-modal .modal-footer button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.3);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.summary-report-modal .modal-footer button:focus:not(:active)::after {
    animation: ripple 0.6s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    100% {
        transform: scale(20, 20);
        opacity: 0;
    }
}
/* 美化导出数据按钮 */
.export-data-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 18px;
    background-color: #2196f3;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(33, 150, 243, 0.3);
    position: relative;
    overflow: hidden;
    min-width: 140px;
}

.export-data-btn:hover {
    background-color: #0d8bf2;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(33, 150, 243, 0.4);
}

.export-data-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 3px rgba(33, 150, 243, 0.4);
}

.export-data-btn i {
    font-size: 20px;
    animation: subtle-float 2s infinite ease-in-out;
}

@keyframes subtle-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* 添加水波纹效果 */
.export-data-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.4);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.export-data-btn:focus:not(:active)::after {
    animation: ripple 0.8s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    100% {
        transform: scale(20, 20);
        opacity: 0;
    }
}