* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f7fa;
    min-height: 100vh;
    padding: 20px;
}

body.auth-pending .container,
body.auth-pending .mobile-container {
    display: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

header {
    background: white;
    color: #333;
    padding: 30px;
    border-bottom: 1px solid #e8e8e8;
}

header h1 {
    margin-bottom: 20px;
    font-size: 2em;
}

nav {
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-left: auto;
}

#username-display {
    color: #666;
    font-size: 14px;
    font-weight: 500;
}

.logout-btn {
    padding: 8px 16px;
    border: 1px solid #dc2626;
    background: white;
    color: #dc2626;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.logout-btn:hover {
    background: #dc2626;
    color: white;
}

.nav-btn {
    padding: 10px 20px;
    border: 1px solid #e0e0e0;
    background: white;
    color: #666;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
}

.nav-btn:hover {
    background: #f8f8f8;
    border-color: #333;
    color: #333;
}

.nav-btn.active {
    background: #333;
    color: white;
    border-color: #333;
}

.nav-link {
    text-decoration: none;
}

.page {
    display: none;
    padding: 30px;
    background: white;
    color: #333;
}

.page.active {
    display: block;
}

/* 筛选栏 */
.filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.filter-bar select,
.filter-bar input {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    background: white;
    color: #333;
}

.filter-bar select:focus,
.filter-bar input:focus {
    outline: none;
    border-color: #333;
}

.filter-bar button {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

#btn-filter {
    background: #333;
    color: white;
}

#btn-filter:hover {
    background: #000;
}

#btn-reset {
    background: #f5f5f5;
    color: #666;
}

#btn-reset:hover {
    background: #e8e8e8;
}

/* 题目列表 */
.question-list {
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    overflow: hidden;
    background: white;
}

.question-list-header {
    display: grid;
    grid-template-columns: 60px 80px 1fr 120px 100px 100px 180px;
    gap: 15px;
    padding: 15px 20px;
    background: #fafafa;
    font-weight: bold;
    border-bottom: 1px solid #e8e8e8;
    color: #666;
}

.question-item {
    display: grid;
    grid-template-columns: 60px 80px 1fr 120px 100px 100px 180px;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #f5f5f5;
    align-items: center;
    transition: background 0.2s;
    color: #333;
}

.question-item:hover {
    background: #fafafa;
}

.question-item:last-child {
    border-bottom: none;
}

.question-id {
    color: #999;
    font-weight: bold;
}

.question-type {
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
}

.type-single {
    background: #e3f2fd;
    color: #1976d2;
}

.type-multiple {
    background: #f3e5f5;
    color: #7b1fa2;
}

.question-content {
    font-size: 14px;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.question-category {
    font-size: 13px;
    color: #666;
}

.difficulty {
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
}

.difficulty-easy {
    background: #e8f5e9;
    color: #388e3c;
}

.difficulty-medium {
    background: #fff3e0;
    color: #f57c00;
}

.difficulty-hard {
    background: #ffebee;
    color: #d32f2f;
}

.question-date {
    font-size: 12px;
    color: #999;
}

.question-actions {
    display: flex;
    gap: 8px;
}

.btn-edit,
.btn-delete {
    padding: 6px 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s;
}

.btn-edit {
    background: #333;
    color: white;
}

.btn-edit:hover {
    background: #000;
}

.btn-delete {
    background: #f44336;
    color: white;
}

.btn-delete:hover {
    background: #d32f2f;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.pagination button {
    padding: 10px 20px;
    border: 1px solid #ddd;
    background: white;
    color: #666;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.pagination button:hover:not(:disabled) {
    background: #333;
    color: white;
    border-color: #333;
}

.pagination button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

#page-info {
    color: #666;
}

/* 表单 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    background: white;
    color: #333;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #333;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.btn-primary,
.btn-secondary {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
}

.btn-primary {
    background: #333;
    color: white;
}

.btn-primary:hover {
    background: #000;
}

.btn-secondary {
    background: #f5f5f5;
    color: #666;
}

.btn-secondary:hover {
    background: #e8e8e8;
}

/* ==================== AI生成页面样式 ==================== */

.ai-upload-section {
    display: grid;
    gap: 30px;
}

/* 上传区域 */
.upload-area {
    border: 2px dashed #ddd;
    border-radius: 10px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: #fafafa;
}

.upload-area:hover {
    border-color: #333;
    background: #f5f5f5;
}

.upload-area.drag-over {
    border-color: #333;
    background: #e8e8e8;
}

.upload-placeholder {
    color: #666;
}

.upload-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.upload-placeholder p {
    margin: 10px 0;
}

.upload-hint {
    font-size: 12px;
    color: #999;
}

.file-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background: white;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.file-name {
    font-size: 14px;
    color: #333;
}

.btn-remove-file {
    background: #f44336;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    transition: all 0.2s;
}

.btn-remove-file:hover {
    background: #d32f2f;
}

/* 生成参数 */
.generate-params {
    background: white;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid #e8e8e8;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.btn-generate {
    width: 100%;
    padding: 15px;
    font-size: 16px;
    font-weight: bold;
    margin-top: 10px;
}

/* 生成进度显示 */
.generate-progress {
    margin-top: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #007bff;
    max-height: 300px;
    overflow-y: auto;
}

.progress-message {
    padding: 8px 0;
    font-size: 14px;
    color: #333;
    line-height: 1.6;
    animation: fadeIn 0.3s ease-in;
}

.progress-error {
    padding: 8px 0;
    font-size: 14px;
    color: #dc3545;
    font-weight: bold;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 预览区域 */
.preview-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e8e8e8;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.preview-header h3 {
    color: #333;
}

.preview-actions {
    display: flex;
    gap: 10px;
}

.preview-metadata {
    display: flex;
    gap: 20px;
    padding: 15px 20px;
    background: #f5f7fa;
    border-radius: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.meta-item {
    font-size: 14px;
    color: #666;
}

.preview-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.preview-item {
    display: flex;
    gap: 15px;
    padding: 20px;
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    transition: all 0.2s;
}

.preview-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.preview-checkbox {
    flex-shrink: 0;
}

.preview-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.preview-content {
    flex: 1;
}

.preview-header-row {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
}

.preview-number {
    font-weight: bold;
    color: #999;
}

.preview-category {
    font-size: 13px;
    color: #666;
    margin-left: auto;
}

.preview-question {
    font-size: 15px;
    font-weight: bold;
    color: #333;
    margin-bottom: 10px;
    line-height: 1.6;
}

.preview-options {
    display: grid;
    gap: 8px;
    margin-bottom: 10px;
}

.preview-option {
    padding: 8px 12px;
    background: #f5f5f5;
    border-radius: 5px;
    font-size: 14px;
    color: #333;
}

.preview-answer {
    padding: 10px 12px;
    background: #e8f5e9;
    border-left: 3px solid #4caf50;
    border-radius: 5px;
    font-size: 14px;
    color: #333;
    margin-bottom: 8px;
}

.preview-explanation {
    padding: 10px 12px;
    background: #fff3e0;
    border-left: 3px solid #ff9800;
    border-radius: 5px;
    font-size: 13px;
    color: #666;
    line-height: 1.6;
}

/* ========== 数据概览页面样式 ========== */

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.dashboard-header h2 {
    color: #333;
    font-size: 1.8em;
    margin: 0;
}

.refresh-btn {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.refresh-btn:hover:not(:disabled) {
    background: #45a049;
}

.refresh-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* 统计卡片 */
.stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    font-size: 2.5em;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    border-radius: 50%;
}

.stat-info h3 {
    font-size: 2em;
    color: #333;
    margin-bottom: 5px;
    font-weight: bold;
}

.stat-info p {
    color: #666;
    font-size: 14px;
    margin: 0;
}

/* 图表容器 */
.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.chart-container {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.chart-container.wide {
    grid-column: span 2;
}

.chart-container h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.2em;
    text-align: center;
}

.chart-container canvas {
    max-height: 300px;
}

/* 质量分析部分 */
.quality-section {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 30px;
}

.quality-section h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.4em;
}

.quality-stats {
    display: grid;
    gap: 20px;
}

.quality-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.quality-label {
    min-width: 120px;
    font-weight: 500;
    color: #333;
}

.progress-bar {
    flex: 1;
    height: 20px;
    background: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50, #45a049);
    border-radius: 10px;
    transition: width 0.6s ease;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.quality-rate {
    min-width: 50px;
    text-align: right;
    font-weight: bold;
    color: #4CAF50;
}

/* 标签云部分 */
.tags-section {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 25px;
}

.tags-section h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.4em;
}

.tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    min-height: 100px;
    align-items: center;
}

.tag-cloud-item {
    padding: 6px 12px;
    border-radius: 20px;
    color: white;
    text-decoration: none;
    transition: transform 0.2s, opacity 0.2s;
    cursor: default;
    font-weight: 500;
}

.tag-cloud-item:hover {
    transform: scale(1.1);
    opacity: 1 !important;
}

.no-data {
    color: #999;
    font-style: italic;
    text-align: center;
    width: 100%;
    padding: 20px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .charts-grid {
        grid-template-columns: 1fr;
    }

    .chart-container.wide {
        grid-column: span 1;
    }

    .stats-cards {
        grid-template-columns: 1fr;
    }

    .dashboard-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .quality-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .progress-bar {
        width: 100%;
    }

    .quality-label {
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .stat-card {
        padding: 20px;
    }

    .stat-icon {
        font-size: 2em;
        width: 50px;
        height: 50px;
    }

    .stat-info h3 {
        font-size: 1.5em;
    }
}





/* ==================== 答题页面样式 ==================== */

/* 答题设置区域 */
.quiz-setup {
    max-width: 600px;
    margin: 0 auto;
}

.quiz-setup h2 {
    margin-bottom: 30px;
    text-align: center;
    color: #333;
}

.quiz-params {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 10px;
}

.btn-start-quiz {
    width: 100%;
    padding: 15px;
    font-size: 16px;
    font-weight: 600;
    margin-top: 20px;
}

/* 答题区域 */
.quiz-area {
    max-width: 900px;
    margin: 0 auto;
}

.quiz-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    margin-bottom: 30px;
}

.quiz-info {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.quiz-info .separator {
    margin: 0 10px;
    color: #999;
}

/* 题目内容区域 */
.quiz-content {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 20px;
}

.question-header {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.badge:nth-child(1) {
    background: #e3f2fd;
    color: #1976d2;
}

.badge:nth-child(2) {
    background: #fff3e0;
    color: #f57c00;
}

.badge:nth-child(3) {
    background: #f3e5f5;
    color: #7b1fa2;
}

.question-content {
    margin-bottom: 30px;
}

.question-content h3 {
    font-size: 20px;
    line-height: 1.6;
    color: #333;
    font-weight: 500;
}

/* 选项列表 */
.options-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.option-item {
    padding: 15px 20px;
    border: 2px solid #e8e8e8;
    border-radius: 8px;
    background: #fafafa;
    cursor: default;
    transition: all 0.2s;
    font-size: 15px;
    line-height: 1.5;
}

.option-item:hover {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

/* 答案和解析区域 */
.answer-section {
    border-top: 1px solid #e8e8e8;
    padding-top: 20px;
}

.btn-show-answer,
.btn-show-explanation {
    padding: 10px 20px;
    border: 1px solid #333;
    background: white;
    color: #333;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    margin-bottom: 15px;
}

.btn-show-answer:hover,
.btn-show-explanation:hover {
    background: #333;
    color: white;
}

.answer-display,
.explanation-display {
    margin-top: 15px;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.answer-box,
.explanation-box {
    padding: 20px;
    background: #e8f5e9;
    border-left: 4px solid #4caf50;
    border-radius: 6px;
}

.answer-box strong,
.explanation-box strong {
    color: #2e7d32;
    display: block;
    margin-bottom: 10px;
}

.answer-box span {
    color: #1b5e20;
    font-size: 16px;
    font-weight: 500;
}

.explanation-box p {
    color: #1b5e20;
    line-height: 1.6;
    margin: 0;
}

/* 导航按钮 */
.quiz-navigation {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.btn-nav {
    flex: 1;
    padding: 12px 24px;
    border: 1px solid #333;
    background: white;
    color: #333;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-nav:hover:not(:disabled) {
    background: #333;
    color: white;
}

.btn-nav:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    border-color: #ccc;
    color: #999;
}

/* 题目导航栏 */
.question-nav-bar {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
}

.nav-bar-title {
    font-size: 14px;
    font-weight: 600;
    color: #666;
    margin-bottom: 15px;
}

.question-nav-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    gap: 10px;
}

.nav-item {
    padding: 10px;
    border: 1px solid #e0e0e0;
    background: white;
    border-radius: 6px;
    text-align: center;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.nav-item:hover {
    background: #f5f5f5;
    border-color: #333;
}

.nav-item.active {
    background: #333;
    color: white;
    border-color: #333;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .quiz-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .quiz-content {
        padding: 20px;
    }

    .question-content h3 {
        font-size: 18px;
    }

    .quiz-navigation {
        flex-direction: column;
    }

    .question-nav-list {
        grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
    }
}


/* ==================== 语音克隆页面样式 ==================== */

.voice-clone-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.voice-clone-header h2 {
    color: #333;
    font-size: 1.8em;
    margin: 0;
}

.voice-section {
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 30px;
}

.voice-section h3 {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.4em;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
}

.voice-section h4 {
    margin-bottom: 15px;
    color: #333;
    font-size: 1.2em;
}

/* 创建音色区域 */
.create-speaker-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.voice-upload {
    min-height: 200px;
}

.speaker-config {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
}

.speaker-config .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

/* 训练进度 */
.training-progress-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
    border-left: 4px solid #007bff;
}

.progress-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.progress-text {
    font-weight: bold;
    color: #333;
    min-width: 100px;
}

.training-details {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

/* 音色列表 */
.speakers-list {
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    overflow: hidden;
}

.speaker-item {
    display: grid;
    grid-template-columns: 120px 1fr 100px 80px 150px 200px;
    gap: 15px;
    padding: 15px 20px;
    border-bottom: 1px solid #f5f5f5;
    align-items: center;
    transition: background 0.2s;
}

.speaker-item:hover {
    background: #fafafa;
}

.speaker-item:last-child {
    border-bottom: none;
}

.speaker-id {
    font-weight: bold;
    color: #333;
    font-size: 14px;
}

.speaker-status {
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
}

.status-unknown {
    background: #f5f5f5;
    color: #666;
}

.status-training {
    background: #fff3e0;
    color: #f57c00;
}

.status-success {
    background: #e8f5e9;
    color: #388e3c;
}

.status-active {
    background: #e3f2fd;
    color: #1976d2;
}

.status-failed {
    background: #ffebee;
    color: #d32f2f;
}

.speaker-model {
    font-size: 13px;
    color: #666;
}

.speaker-language {
    font-size: 13px;
    color: #666;
}

.speaker-actions {
    display: flex;
    gap: 8px;
}

.btn-train,
.btn-delete-speaker,
.btn-view-detail {
    padding: 6px 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s;
}

.btn-train {
    background: #2196f3;
    color: white;
}

.btn-train:hover {
    background: #1976d2;
}

.btn-delete-speaker {
    background: #f44336;
    color: white;
}

.btn-delete-speaker:hover {
    background: #d32f2f;
}

.btn-view-detail {
    background: #4caf50;
    color: white;
}

.btn-view-detail:hover {
    background: #388e3c;
}

/* 语音合成区域 */
.synthesis-config {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
}

.synthesis-config .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.text-counter {
    text-align: right;
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* 语速滑块样式 */
input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #333;
    cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #333;
    cursor: pointer;
    border: none;
}

#speed-ratio-value {
    margin-left: 10px;
    font-weight: bold;
    color: #333;
}

/* 合成结果 */
.synthesis-result-section {
    margin-top: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #4caf50;
}

.result-info {
    display: grid;
    gap: 15px;
}

.audio-player {
    background: white;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e8e8e8;
}

.audio-controls {
    display: flex;
    gap: 10px;
}

.audio-details {
    display: flex;
    gap: 20px;
    font-size: 14px;
    color: #666;
}

/* 音色详情弹窗 */
.speaker-detail-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    border-radius: 10px;
    padding: 30px;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e8e8e8;
}

.modal-header h3 {
    margin: 0;
    color: #333;
}

.btn-close-modal {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.btn-close-modal:hover {
    background: #f5f5f5;
    color: #333;
}

.detail-section {
    margin-bottom: 25px;
}

.detail-section h4 {
    margin-bottom: 15px;
    color: #333;
    font-size: 1.1em;
}

.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 5px;
    font-size: 14px;
}

.detail-label {
    font-weight: bold;
    color: #666;
}

.detail-value {
    color: #333;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.history-item {
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid #007bff;
}

.history-item h5 {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: #333;
}

.history-item p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

/* 语音克隆页面响应式设计 */
@media (max-width: 768px) {
    .create-speaker-section {
        grid-template-columns: 1fr;
    }

    .speaker-config .form-row {
        grid-template-columns: 1fr;
    }

    .speaker-item {
        grid-template-columns: 1fr;
        gap: 8px;
        text-align: left;
    }

    .synthesis-config .form-row {
        grid-template-columns: 1fr;
    }

    .modal-content {
        margin: 20px;
        max-width: none;
    }

    .detail-grid {
        grid-template-columns: 1fr;
    }
}
