/* 主容器样式 */
.home-container {
    padding-top: 80px; /* 为固定导航栏留出空间 */
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px 20px;
}

/* 搜索区域样式 */
.search-section {
    margin: 20px 0;
    text-align: center;
}

.search-box {
    display: flex;
    max-width: 600px;
    margin: 0 auto;
    gap: 10px;
    align-items: center;
}

#searchInput {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.search-btn {
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.advanced-search {
    color: #3498db;
    text-decoration: none;
}

/* 数据库介绍样式 */
.database-intro {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

.intro-content {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    margin: 20px 0;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.intro-text {
    flex: 1;
    font-size: 16px;
    line-height: 1.6;
}

.intro-image {
    flex: 1.2;
    position: relative;
}

.graphic-abstract-img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.image-citation {
    font-size: 12px;
    color: #666;
    margin-top: 10px;
    line-height: 1.4;
    font-style: italic;
}

/* 新增食品微生物展示区域样式 */
.food-microbiome-showcase {
    margin: 40px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.showcase-content {
    display: flex;
    align-items: center;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.food-microbiome-img {
    width: 50%;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.showcase-text {
    flex: 1;
}

.showcase-text h3 {
    color: #2c3e50;
    margin-bottom: 15px;
    font-size: 24px;
}

.showcase-text p {
    color: #555;
    line-height: 1.6;
    font-size: 16px;
}

/* 响应式布局 */
@media (max-width: 768px) {
    .intro-content,
    .showcase-content {
        flex-direction: column;
    }
    
    .intro-image,
    .food-microbiome-img {
        width: 100%;
        margin-top: 20px;
    }
    
    .showcase-text {
        margin-top: 20px;
        text-align: center;
    }
}

/* 最新研究样式 */
.latest-studies {
    margin: 15px 0;
}

.studies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.study-card {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.study-card h3 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.study-card p {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

/* 使用指南样式 */
.usage-guide {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

h2 {
    color: #2c3e50;
    margin-bottom: 20px;
}

/* 在现有样式的基础上添加 */
.page-content {
    display: none;
}

.page-content.active {
    display: block;
}

/* 搜索页面样式 */
.search-container {
    padding-top: 80px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px 20px;
}

.search-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.main-search {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.search-button {
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* 高级索区域 */
.advanced-search-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin-top: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.search-builder {
    margin-bottom: 15px;
}

.search-group {
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 15px;
    background: white;
}

.group-operator {
    margin-bottom: 10px;
    padding: 5px 10px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    background: #e9ecef;
    font-weight: bold;
}

.condition {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    align-items: center;
}

.condition select,
.condition input {
    padding: 6px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
}

.field-select {
    min-width: 150px;
    flex: 2;
}

.operator {
    min-width: 140px;
    flex: 1.5;
}

.condition-value {
    flex: 3;
}

.remove-condition {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 20px;
    cursor: pointer;
    padding: 0 5px;
    flex: 0;
}

.add-condition {
    background: #e9ecef;
    border: 1px dashed #ced4da;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    margin-top: 10px;
    transition: all 0.3s ease;
}

.add-condition:hover {
    background: #dee2e6;
}

.search-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 15px;
}

.apply-search,
.clear-search {
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.apply-search {
    background: #0d6efd;
    border: 1px solid #0d6efd;
    color: white;
}

.apply-search:hover {
    background: #0b5ed7;
}

.clear-search {
    background: white;
    border: 1px solid #6c757d;
    color: #6c757d;
}

.clear-search:hover {
    background: #6c757d;
    color: white;
}

/* 结果类型选择 */
.result-type-selection {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.type-option {
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
}

/* 筛选区域 */
.filter-section {
    display: flex;
    gap: 20px;
}

.filter-sidebar {
    width: 300px;
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 4px;
}

.filter-group {
    margin-bottom: 20px;
}

.filter-group h4 {
    margin-bottom: 10px;
    color: #2c3e50;
}

.checkbox-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.range-input {
    display: flex;
    gap: 10px;
    align-items: center;
}

.range-input input {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 100px;
}

.clear-filter {
    width: 100%;
    padding: 10px;
    background-color: #95a5a6;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* 结果表格容器 */
.results-table {
    flex: 1;
    border: 1px solid #ddd;
    border-radius: 4px;
    position: relative;
    max-width: 100%;
    overflow: hidden;
}

/* 表格滚动容器 */
.table-container {
    overflow-x: auto;
    width: 100%;
    padding-right: 50px; /* 改用 padding 而不是 margin */
}

/* 表格基础样式 */
.results-table table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    position: relative; /* 添加相对定位 */
}

/* 固定表头 */
.results-table thead {
    position: sticky;
    top: 0;
    z-index: 2;
    background-color: #f8f9fa;
}

/* 固定最后一列（包括表头和数据单元格） */
.results-table th:last-child,
.results-table td:last-child {
    position: sticky; /* 改用 sticky 定位 */
    right: 0;
    width: 50px;
    min-width: 50px;
    z-index: 2;
}

/* 特别处理表头最后一列 */
.results-table thead th:last-child {
    position: sticky;
    right: 0;
    z-index: 3; /* 确保在其他元素之上 */
    background-color: #f8f9fa;
    border-left: 1px solid #ddd;
}

/* 表格单元格基础样式 */
.results-table th,
.results-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background-color: inherit; /* 继承背景色 */
}

/* 确保最后一列的背景色 */
.results-table tbody td:last-child {
    background-color: white;
    border-left: 1px solid #ddd;
}

/* 为固定列添加阴影效果 */
.results-table th:last-child::before,
.results-table td:last-child::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 0;
    bottom: 0;
    width: 6px;
    background: linear-gradient(to right, rgba(0,0,0,0.05), rgba(0,0,0,0));
    pointer-events: none;
}

/* 行悬停效果 */
.results-table tbody tr:hover td {
    background-color: #f5f5f5;
}

.results-table tbody tr:hover td:last-child {
    background-color: #f5f5f5;
}

/* 分页控件 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
    background-color: #f8f9fa;
    border-top: 1px solid #ddd;
}

.pagination button {
    padding: 5px 10px;
    margin: 0 5px;
    border: 1px solid #ddd;
    background-color: white;
    cursor: pointer;
    border-radius: 3px;
}

.pagination button:hover {
    background-color: #e9ecef;
}

.pagination button:disabled {
    background-color: #f8f9fa;
    cursor: not-allowed;
}

.pagination span {
    margin: 0 10px;
}

/* 在分页控件样式中添加 */
.page-size-selector {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-right: 20px;
}

.page-size-selector select {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 3px;
    background-color: white;
    cursor: pointer;
}

.page-size-selector select:hover {
    border-color: #3498db;
}

/* 添加复选框样式 */
.results-table input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.results-table th:first-child,
.results-table td:first-child {
    width: 40px;
    min-width: 40px;
}

.results-table th:last-child,
.results-table td:last-child {
    width: 50px;
    min-width: 50px;
}

.results-table td:not(:first-child):not(:last-child),
.results-table th:not(:first-child):not(:last-child) {
    width: 150px;
    max-width: 150px;
}

/* 修改表格单元格的悬浮提示样式 */
/* .results-table td:hover::after {
    content: attr(title);
    position: fixed;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    z-index: 1000;
    white-space: normal;
    max-width: 300px;
    word-wrap: break-word;
    pointer-events: none;
} */

/* 添加JavaScript控制提示框位置的样式 */
.tooltip {
    position: fixed;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    z-index: 1000;
    pointer-events: none;
    max-width: 300px;
    word-wrap: break-word;
    display: none;
    font-size: 14px;
    line-height: 1.4;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Statistics页面样式 */
.statistics-container {
    padding: 80px 20px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.chart-controls {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.chart-controls h3 {
    margin-bottom: 10px;
    color: #2c3e50;
}

.chart-controls select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: white;
}

.selected-items {
    grid-column: 1 / -1;
}

#selectedItemsList {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
    background-color: white;
}

.axis-selection {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.generate-btn {
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    grid-column: 1 / -1;
}

.generate-btn:hover {
    background-color: #2980b9;
}

.chart-container {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    height: 500px;
}

/* 已选择数据列表样式 */
.selected-items-header {
    margin-bottom: 10px;
    padding: 5px;
    border-bottom: 1px solid #ddd;
}

.selected-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px;
}

.selected-item:hover {
    background-color: #f5f5f5;
}

.stats-item-checkbox {
    cursor: pointer;
}

.selected-item label {
    cursor: pointer;
    flex: 1;
}

#selectAllStats {
    cursor: pointer;
    margin-right: 5px;
}

/* Dendrogram页面样式 */
.dendrogram-container {
    padding-top: 80px; /* 为固定导航栏留出空间 */
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px 20px;
}

/* Dendrogram页面定样式 */
.dendrogram-container .chart-controls {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.dendrogram-container .selected-items {
    grid-column: 1 / -1;
}

#dendrogramSelectedItems {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
    background-color: white;
}

.taxonomy-selection {
    grid-column: 1 / -1;
}

.taxonomy-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
    padding: 15px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    max-height: 200px;
    overflow-y: auto;
}

.taxonomy-options label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    max-width: 100%;  /* 确保label不会超出容器 */
}

/* 添加一个包装span来控制文本溢出 */
.taxonomy-options label span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;  /* 让文本占据剩余空间 */
}

.taxonomy-options label:hover {
    background-color: #f5f5f5;
}

.taxonomy-options input[type="checkbox"] {
    margin: 0;
    cursor: pointer;
    min-width: 16px;
    min-height: 16px;
}

.dendrogram-chart {
    display: none;
    width: 100%;
    height: 600px;
    border: 1px solid #ddd;
    margin-top: 20px;
}

.dendrogram-chart.active {
    display: block;
    border: 1px solid #ddd;
}

.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    font-size: 1.2em;
    color: #666;
}

.chart-btn {
    padding: 8px 16px;
    margin: 0 5px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
}

.chart-btn.active {
    background: #007bff;
    color: white;
    border-color: #0056b3;
}

/* 共用的控件样式 */
.chart-controls h3 {
    margin-bottom: 10px;
    color: #2c3e50;
}

.chart-controls select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: white;
}

.selected-items-header {
    margin-bottom: 10px;
    padding: 5px;
    border-bottom: 1px solid #ddd;
}

.selected-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px;
}

.selected-item:hover {
    background-color: #f5f5f5;
}

/* 添加单选按钮样式 */
.chart-type-radio {
    display: flex;
    gap: 20px;
    padding: 10px;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.chart-type-radio label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.chart-type-radio input[type="radio"] {
    cursor: pointer;
}

.chart-type-radio label:hover {
    color: #3498db;
}

/* 在已有的样式文件末尾添加 */
.chart-type-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 10px;
}

.chart-btn {
    padding: 10px 24px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #f8f9fa;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    white-space: nowrap;
}

.chart-btn:hover {
    background-color: #e9ecef;
}

.chart-btn.active {
    background-color: #3498db;
    color: white;
    border-color: #3498db;
}

/* 查看按钮样式 */
.view-button {
    padding: 4px 8px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.view-button:hover {
    background-color: #2980b9;
}

/* 详情模态框样式 */
.detail-modal {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    max-width: 80%;
    max-height: 80%;
    overflow-y: auto;
    position: relative;
}

.close-button {
    position: absolute;
    right: 10px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.close-button:hover {
    color: #333;
}

.detail-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.detail-table td {
    padding: 8px;
    border: 1px solid #ddd;
}

.detail-table tr td:first-child {
    font-weight: bold;
    background-color: #f8f9fa;
    width: 200px;
}

/* 修改已选择数据项的样式 */
.selected-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px;
}

.item-label-container {
    display: flex;
    gap: 8px;
    align-items: center;
    flex: 1;
    overflow: hidden;
}

.item-id {
    font-weight: 500;
    white-space: nowrap;
}

.item-sample {
    color: #666;
    font-size: 0.9em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.abundance-switch {
    display: flex;
    align-items: center;
    margin-top: 10px;
    gap: 10px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: #2196F3;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

.data-type-display {
    display: inline-block;
    padding: 8px 12px;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 14px;
    color: #495057;
    min-width: 80px;
    text-transform: capitalize;
}

.data-type-selection {
    margin-bottom: 15px;
}

/* 添加以下样式 */
.sample-only {
    display: block;
}

.data-type-display[data-type="sample"] ~ .sample-only {
    display: block;
}

/* 添加图标相关样式 */
.nav-item i {
    margin-right: 8px;
}

.logo i {
    margin-right: 10px;
    color: #4a90e2;
}

h2 i, h3 i {
    margin-right: 10px;
    color: #4a90e2;
}

button i {
    margin-right: 6px;
}

/* 调整图标大小和间距 */
.fas {
    font-size: 0.9em;
}

/* 搜索按钮图标样式 */
.search-button i {
    margin-right: 5px;
}

/* 重置按钮图标样式 */
.reset-button i {
    margin-right: 5px;
}

/* 高级搜索按钮标样式 */
.toggle-advanced-search i {
    margin-right: 5px;
}

/* 更新高级搜索按钮样式 */
.toggle-advanced-search {
    padding: 10px 20px;
    background-color: #4a90e2;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.toggle-advanced-search:hover {
    background-color: #357abd;
}

.toggle-advanced-search.active {
    background-color: #357abd;
}

/* 更新条件选择器样式 */
.operator {
    min-width: 140px; /* 增加宽度以适应更长的选项文本 */
}

.condition select {
    background-color: white;
    cursor: pointer;
}

.condition select:hover {
    border-color: #4a90e2;
}

/* 添加一些过渡效果 */
.advanced-search-section {
    transition: all 0.3s ease;
}

.condition {
    transition: all 0.3s ease;
}

/* 添加一些动画效果 */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.advanced-search-section {
    animation: slideDown 0.3s ease;
}

/* 高亮样式 */
.highlight {
    background-color: #fff3cd;
    padding: 2px;
    border-radius: 2px;
    font-weight: bold;
}

/* 悬浮提示样式 */
.tooltip {
    position: fixed;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1001;
    max-width: 300px;
    white-space: normal;
    pointer-events: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    line-height: 1.4;
}

/* 添加tooltip箭头 */
.tooltip::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 5px 5px;
    border-style: solid;
    border-color: transparent transparent rgba(0, 0, 0, 0.8) transparent;
}

/* 更新表头信息图标样式 */
.info-icon {
    color: #666;
    font-size: 14px;
    margin-right: 5px;
    cursor: help;
    position: relative;
    z-index: 1000;
}

.info-icon:hover {
    color: #333;
}

/* Statistics页面样式 */
.statistics-container {
    padding: 80px 20px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.chart-controls {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.chart-type-selection,
.axis-config {
    background: white;
    padding: 15px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.axis-config {
    display: grid;
    gap: 15px;
}

.axis-selection {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.axis-select,
.chart-select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: white;
    font-size: 14px;
}

.chart-display {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    min-height: 500px;
    margin-top: 20px;
}

/* 控制Y轴和分类选择的显示/隐藏 */
.y-axis-config,
.hue-config {
    display: none;
}

.y-axis-config.show,
.hue-config.show {
    display: block;
}

/* 图表生成按钮样式 */
.generate-btn {
    grid-column: 1 / -1;
    padding: 12px 24px;
    background-color: #4a90e2;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
}

.generate-btn:hover {
    background-color: #357abd;
}

.generate-btn i {
    margin-right: 8px;
}

/* 数据类型选择样式 */
.type-options {
    display: flex;
    gap: 20px;
    margin-top: 10px;
}

.type-option {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 16px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.type-option:hover {
    border-color: #4a90e2;
}

.type-option input[type="radio"] {
    margin: 0;
}

.type-option input[type="radio"]:checked + span {
    color: #4a90e2;
    font-weight: 500;
}

/* 已选择数据项样式更新 */
.selected-items {
    background: white;
    padding: 15px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

#statsSelectedItems {
    max-height: 200px;
    overflow-y: auto;
    margin-top: 10px;
}

.selected-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border-bottom: 1px solid #eee;
}

.selected-item:last-child {
    border-bottom: none;
}

.selected-item:hover {
    background-color: #f8f9fa;
}

.stats-item-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.selected-item label {
    flex: 1;
    cursor: pointer;
    margin: 0;
}