/* ========== 变量系统 ========== */
:root {
    --primary: #1a1a2e;
    --primary-light: #16213e;
    --accent: #c9a96e;
    --accent-dark: #b8954a;
    --text: #2d3748;
    --text-light: #718096;
    --text-white: #ffffff;
    --bg: #f7fafc;
    --bg-card: #ffffff;
    --border: #e2e8f0;
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: all 0.3s ease;
    
    --blue: #3182ce;
    --blue-bg: #ebf8ff;
    --amber: #c9a96e;
    --amber-bg: #fffaf0;
    --green: #38a169;
    --green-bg: #f0fff4;
    --red: #e53e3e;
    --red-bg: #fff5f5;
    --purple: #805ad5;
    --purple-bg: #faf5ff;
}

/* ========== 基础重置 ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

/* ========== 导航栏 ========== */
.navbar {
    background: var(--primary);
    color: var(--text-white);
    padding: 0 32px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 16px;
}

.brand-icon {
    color: var(--accent);
    font-size: 20px;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    padding: 4px 0;
    border-bottom: 2px solid transparent;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-white);
    border-bottom-color: var(--accent);
}

/* ========== 主容器 ========== */
.main-container {
    padding-top: 60px;
    min-height: 100vh;
}

/* ========== 搜索区域 ========== */
.search-section {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 60px - 48px);
    padding: 40px 24px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    position: relative;
    overflow: hidden;
}

.search-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(201,169,110,0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.search-container {
    max-width: 640px;
    width: 100%;
    text-align: center;
    position: relative;
    z-index: 1;
}

.search-title {
    font-size: 42px;
    font-weight: 700;
    color: var(--text-white);
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

/* ========== 模型选择器 ========== */
.model-selector {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 28px;
}

.model-option {
    cursor: pointer;
    display: flex;
    align-items: center;
}

.model-option input[type="radio"] {
    display: none;
}

.model-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 24px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    background: rgba(255,255,255,0.05);
    transition: all 0.2s;
    min-width: 140px;
}

.model-option:hover .model-card {
    border-color: rgba(255,255,255,0.4);
    background: rgba(255,255,255,0.08);
}

.model-option input[type="radio"]:checked + .model-card {
    border-color: var(--accent-color, #C5A880);
    background: rgba(197,168,128,0.15);
}

.model-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-white);
    margin-bottom: 2px;
}

.model-desc {
    font-size: 11px;
    color: rgba(255,255,255,0.5);
    margin-bottom: 4px;
}

.model-tag {
    font-size: 10px;
    color: var(--accent-color, #C5A880);
    background: rgba(197,168,128,0.12);
    padding: 1px 8px;
    border-radius: 10px;
    font-family: 'SF Mono', Consolas, monospace;
    letter-spacing: 0.3px;
}

/* ========== 补充信息框（含两按钮）========== */
.supplement-box {
    margin-top: 16px;
    padding: 12px;
    background: var(--bg);
    border-radius: 8px;
    border: 1px dashed var(--border);
}
.supplement-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
}
.supplement-next-btn {
    padding: 8px 28px;
    font-size: 14px;
}
.supplement-regen-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.search-subtitle {
    font-size: 16px;
    color: rgba(255,255,255,0.6);
    margin-bottom: 40px;
    font-weight: 400;
}

/* ========== 搜索表单 ========== */
.search-form {
    max-width: 640px;
    margin: 0 auto;
    text-align: left;
}

.form-group {
    margin-bottom: 16px;
}

.strategy-hints {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hint-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hint-label {
    flex-shrink: 0;
    width: 72px;
    font-size: 12px;
    color: var(--text-secondary, #64748b);
    text-align: right;
}

.hint-row input {
    flex: 1;
    padding: 6px 10px;
    border: 1px solid var(--border, #e2e8f0);
    border-radius: 6px;
    font-size: 13px;
    background: var(--paper, #f8fafc);
    transition: border-color 0.2s;
}

.hint-row input:focus {
    outline: none;
    border-color: var(--primary, #0071E3);
    background: #fff;
}

.form-row {
    display: flex;
    gap: 16px;
}

.form-row .form-group {
    flex: 1;
}

.form-label {
    display: block;
    color: rgba(255,255,255,0.7);
    font-size: 13px;
    margin-bottom: 6px;
    font-weight: 500;
}

.form-label .required {
    color: #e53e3e;
}

.search-form input,
.search-form textarea {
    width: 100%;
    padding: 10px 14px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: var(--transition);
}

.search-form input::placeholder,
.search-form textarea::placeholder {
    color: rgba(255,255,255,0.35);
}

.search-form input:focus,
.search-form textarea:focus {
    border-color: var(--accent);
    background: rgba(255,255,255,0.12);
}

.search-form textarea {
    resize: vertical;
    font-family: inherit;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 4px;
}

/* ========== 按钮系统 ========== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 28px;
    background: var(--accent);
    color: var(--primary);
    border: none;
    border-radius: var(--radius);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-primary:hover {
    background: var(--accent-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(201,169,110,0.4);
}

.btn-sm {
    padding: 6px 16px;
    font-size: 13px;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-outline:hover {
    background: var(--bg);
    color: var(--text);
    border-color: var(--text-light);
}

.btn-large {
    padding: 18px 36px;
    font-size: 16px;
}

/* ========== 快速标签 ========== */
.quick-tags {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.quick-label {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
}

.quick-tag {
    padding: 6px 16px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 20px;
    color: rgba(255,255,255,0.8);
    font-size: 13px;
    cursor: pointer;
    transition: var(--transition);
}

.quick-tag:hover {
    background: rgba(201,169,110,0.2);
    border-color: var(--accent);
    color: var(--accent);
}

/* ========== 资料上传区 ========== */
.upload-section {
    margin-top: 20px;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
}

.upload-dropzone {
    border: 2px dashed rgba(255,255,255,0.15);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    color: rgba(255,255,255,0.6);
}

.upload-dropzone:hover,
.upload-dropzone.dragover {
    border-color: var(--accent);
    background: rgba(201,169,110,0.06);
    color: var(--accent);
}

.dropzone-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.dropzone-sub {
    font-size: 11px;
    opacity: 0.6;
}

.upload-list {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.upload-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    color: rgba(255,255,255,0.8);
}

.upload-item-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-item-size { color: rgba(255,255,255,0.4); margin: 0 12px; font-size: 11px; }
.upload-item-status { color: var(--accent); font-size: 11px; margin-right: 8px; }
.upload-item-status.error { color: #e53e3e; }
.upload-item-delete {
    background: none; border: none; color: rgba(255,255,255,0.4);
    cursor: pointer; font-size: 16px; padding: 0 4px; line-height: 1;
}
.upload-item-delete:hover { color: #e53e3e; }

/* ========== 仪表盘区域 ========== */
.dashboard-section {
    padding: 32px;
    max-width: 1400px;
    margin: 0 auto;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== 公司头部 ========== */
.company-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 28px;
    padding: 24px 28px;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border-left: 4px solid var(--accent);
}

.company-info h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

.company-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: var(--text-light);
}

.divider {
    color: var(--border);
}

.company-actions {
    display: flex;
    gap: 12px;
}

/* ========== 步骤导航 ========== */
.step-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 28px;
    padding: 16px 20px;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    overflow-x: auto;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    border: 2px solid transparent;
}

.step-item:hover {
    background: var(--bg);
}

.step-item.active {
    background: var(--primary);
    color: var(--text-white);
    border-color: var(--primary);
}

.step-item.completed {
    background: var(--green-bg);
    border-color: var(--green);
    color: var(--green);
}

.step-item.pending {
    background: var(--bg);
    border-color: var(--border);
    color: var(--text-light);
    cursor: pointer;
}

.step-item.pending:hover {
    background: var(--amber-bg);
    border-color: var(--accent);
    color: var(--accent);
}

.step-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.2;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 12px;
}

.step-item.active .step-num {
    background: var(--accent);
    opacity: 1;
    color: var(--primary);
}

.step-item.completed .step-num {
    background: var(--green);
    opacity: 1;
    color: var(--text-white);
}

.step-label {
    font-size: 13px;
    font-weight: 600;
}

.step-arrow {
    color: var(--border);
    font-size: 14px;
    font-weight: 700;
}

/* ========== 步骤内容区 ========== */
.step-content {
    animation: fadeIn 0.3s ease;
}

/* ========== 步骤头部 ========== */
.step-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding: 16px 24px;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border-left: 4px solid var(--accent);
}

.step-header h3 {
    margin: 0;
    font-size: 18px;
}

.step-subtitle {
    font-size: 13px;
    color: var(--text-light);
    margin-left: 12px;
}

.step-header h3 + .step-subtitle,
.step-subtitle {
    font-weight: 400;
    color: var(--text-light);
}

.step-regen-btn {
    margin-left: auto;
    white-space: nowrap;
    flex-shrink: 0;
}

.step-regen-btn.disabled-regen {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

.quota-hint {
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    margin-left: auto;
    white-space: nowrap;
}

/* ========== 可编辑内容区 ========== */
.editable-content {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
}

/* ========== 步骤底部操作栏 ========== */
.step-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 12px 24px;
    background: var(--bg-card);
    border-radius: 0 0 var(--radius) var(--radius);
    border-top: 2px solid var(--accent);
    box-shadow: var(--shadow);
    margin-top: -4px;
}

.dirty-hint {
    font-size: 12px;
    color: var(--accent);
    font-weight: 500;
    margin-right: auto;
}

/* ========== 补充信息输入框 ========== */
.supplement-area {
    margin-top: 24px;
    padding: 12px 16px;
    background: var(--bg);
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
}

.supplement-area label {
    display: block;
    font-size: 12px;
    color: var(--text-light);
    margin-bottom: 6px;
}

.supplement-area textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 13px;
    color: var(--text);
    resize: vertical;
    outline: none;
    transition: var(--transition);
}

.supplement-area textarea:focus {
    border-color: var(--accent);
}

/* ========== 岗位确认选择 ========== */
.job-confirm-section {
    margin: 24px 0;
    padding: 16px 20px;
    background: var(--amber-bg);
    border: 1px solid var(--accent);
    border-radius: var(--radius-sm);
}

.job-confirm-section h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 12px;
}

.job-confirm-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.job-confirm-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--text);
}

.job-confirm-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
}

.btn-confirm-jobs {
    padding: 8px 20px;
    background: var(--accent);
    color: var(--primary);
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-confirm-jobs:hover {
    background: var(--accent-dark);
}

/* ========== 模块分组（知企业/懂岗位/明场景） ========== */
.module-group {
    margin-bottom: 32px;
}

.module-group-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 16px;
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--text-white);
    border-radius: var(--radius-sm);
    letter-spacing: 2px;
}

.module-group:nth-child(1) .module-group-title {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

.module-group:nth-child(2) .module-group-title {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
}

.module-group:nth-child(3) .module-group-title {
    background: linear-gradient(135deg, #805ad5 0%, #6b46c1 100%);
}

/* ========== 确认区块 ========== */
.confirm-block {
    margin-bottom: 20px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-card);
}

.confirm-block-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border);
}

.confirm-block-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--primary);
    color: var(--text-white);
    font-size: 14px;
    font-weight: 700;
}

.confirm-block-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    flex: 1;
}

.confirm-status {
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 6px;
    background: var(--bg);
    color: var(--text-light);
}

.confirm-status.confirmed {
    background: var(--green-bg);
    color: var(--green);
}

.confirm-status.rejected {
    background: var(--red-bg);
    color: var(--red);
}

.confirm-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px dashed var(--border);
}

.btn-confirm {
    padding: 6px 16px;
    border: 1px solid var(--green);
    background: var(--green-bg);
    color: var(--green);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-confirm:hover {
    background: var(--green);
    color: var(--text-white);
}

.btn-reject {
    padding: 6px 16px;
    border: 1px solid var(--red);
    background: var(--red-bg);
    color: var(--red);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-reject:hover {
    background: var(--red);
    color: var(--text-white);
}

.editable-section {
    margin-bottom: 24px;
}

.editable-section:last-child {
    margin-bottom: 0;
}

.editable-section-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(201,169,110,0.2);
}

.editable-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.editable-table th {
    background: rgba(0,0,0,0.03);
    padding: 8px 10px;
    text-align: left;
    font-weight: 500;
    color: var(--text-light);
    border-bottom: 2px solid var(--border);
    font-size: 12px;
}

.editable-table td {
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
    line-height: 1.5;
}

.editable-table td[contenteditable]:focus {
    background: rgba(201,169,110,0.08);
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    border-radius: 2px;
}

.editable-list {
    list-style: none;
    padding: 0;
}

.editable-list li {
    padding: 4px 0;
    font-size: 13px;
    line-height: 1.6;
}

.editable-list li[contenteditable]:focus {
    background: rgba(201,169,110,0.08);
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    border-radius: 2px;
}

/* ========== PPT脚本页卡片 ========== */
.ppt-page-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: var(--transition);
}

.ppt-page-card:hover {
    box-shadow: var(--shadow);
    border-color: rgba(201,169,110,0.3);
}

.ppt-page-num {
    font-size: 11px;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ppt-page-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--primary);
}

.ppt-page-title[contenteditable]:focus {
    background: rgba(201,169,110,0.08);
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    border-radius: 2px;
}

.ppt-module-item {
    font-size: 13px;
    padding: 6px 0 6px 16px;
    position: relative;
    line-height: 1.5;
}

.ppt-module-item::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

.ppt-module-item[contenteditable]:focus {
    background: rgba(201,169,110,0.08);
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    border-radius: 2px;
}

/* ========== 数据表格（兼容旧样式） ========== */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table th {
    text-align: left;
    padding: 12px 16px;
    background: var(--bg);
    color: var(--text-light);
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border);
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    vertical-align: top;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover td {
    background: var(--bg);
}

/* ========== 信息行 ========== */
.info-row {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    width: 80px;
    font-size: 13px;
    color: var(--text-light);
    font-weight: 500;
    flex-shrink: 0;
}

.info-value {
    flex: 1;
    font-size: 14px;
    color: var(--text);
    line-height: 1.5;
}

/* ========== 洞察块 ========== */
.insight-block {
    margin-bottom: 20px;
}

.insight-block:last-child {
    margin-bottom: 0;
}

.insight-block h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.insight-block p {
    font-size: 14px;
    color: var(--text);
    line-height: 1.6;
}

.insight-block ul {
    list-style: none;
}

.insight-block li {
    font-size: 14px;
    color: var(--text);
    padding: 6px 0;
    padding-left: 20px;
    position: relative;
}

.insight-block li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

/* ========== 弹窗 ========== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--bg-card);
    border-radius: var(--radius);
    width: 90%;
    max-width: 640px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-light);
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* ========== PPT 动作区 ========== */
.ppt-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 20px 0;
}

/* ========== 加载覆盖层 ========== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255,255,255,0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 300;
    gap: 16px;
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-overlay p {
    color: var(--text-light);
    font-size: 14px;
}

.loading-stream {
    max-width: 720px;
    max-height: 30vh;
    width: 90%;
    overflow-y: auto;
    padding: 16px;
    background: #f8f9fa;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: var(--mono, monospace);
    font-size: 13px;
    line-height: 1.6;
    color: var(--text);
    white-space: pre-wrap;
    word-break: break-word;
    text-align: left;
}

.loading-sections {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 720px;
    max-height: 35vh;
    width: 90%;
    overflow-y: auto;
    padding-right: 4px;
}

.loading-section-card {
    background: #fff;
    border: 1px solid var(--border);
    border-left: 4px solid var(--primary);
    border-radius: 8px;
    padding: 12px 14px;
    text-align: left;
    box-shadow: 0 2px 6px rgba(0,0,0,0.04);
    animation: fadeInUp 0.3s ease;
}

.loading-section-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 8px;
}

.loading-section-body {
    font-size: 13px;
    color: var(--text);
    line-height: 1.5;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== 页脚 ========== */
.footer {
    text-align: center;
    padding: 20px;
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    background: var(--primary);
}

.footer-beian {
    margin-top: 6px;
    font-size: 12px;
}

.footer-beian a {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-beian a:hover {
    color: rgba(255,255,255,0.8);
    text-decoration: underline;
}

/* ========== 品牌版本 ========== */
.brand-version {
    font-size: 11px;
    color: var(--accent);
    background: rgba(201, 169, 110, 0.15);
    padding: 2px 8px;
    border-radius: 4px;
    margin-left: 8px;
    font-weight: 600;
}

/* ========== 工具类 ========== */
.hidden {
    display: none !important;
}

/* ========== 项目历史模态框 ========== */
.project-list {
    max-height: 400px;
    overflow-y: auto;
}

.project-item {
    padding: 16px;
    background: var(--bg);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.project-item:hover {
    border-color: var(--accent);
    background: var(--amber-bg);
}

.project-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.project-name {
    font-weight: 700;
    font-size: 16px;
    color: var(--primary);
}

.project-industry {
    padding: 2px 10px;
    background: var(--accent);
    color: var(--primary);
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.project-date {
    font-size: 13px;
    color: var(--text-light);
    margin-left: auto;
}

.project-meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: var(--text-light);
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--text-light);
    font-size: 14px;
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
    .search-title {
        font-size: 28px;
    }
    
    .company-header {
        flex-direction: column;
        gap: 16px;
    }
    
    .company-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .step-nav {
        gap: 4px;
        padding: 12px 16px;
    }
    
    .step-item {
        padding: 8px 12px;
        gap: 6px;
    }
    
    .step-label {
        font-size: 12px;
    }
    
    .step-arrow {
        display: none;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
}

@media (max-width: 600px) {
    .navbar {
        padding: 0 16px;
    }
    
    .nav-links {
        display: none;
    }
    
    .dashboard-section {
        padding: 16px;
    }
    
    .search-title {
        font-size: 24px;
    }
    
    .modal-content {
        width: 95%;
        max-height: 90vh;
    }
    
    .step-nav {
        flex-wrap: wrap;
    }
    
    .step-item {
        flex: 1;
        min-width: 80px;
        justify-content: center;
    }
    
    .step-num {
        display: none;
    }
    
    .step-header {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    
    .editable-content {
        padding: 16px;
    }
    
    .editable-table {
        font-size: 12px;
    }
    
    .editable-table th,
    .editable-table td {
        padding: 6px 8px;
    }
    
    .ppt-page-card {
        padding: 14px;
    }
}

/* ========== 移动端适配增强 ========== */

body {
    padding-bottom: env(safe-area-inset-bottom, 0);
}

/* 触摸反馈类（由 JS 在 touchstart 时添加） */
.touch-active {
    transform: scale(0.98) !important;
    transition: transform 0.1s ease !important;
}

/* 虚拟键盘升起时隐藏底部固定导航 */
body.keyboard-open .mobile-step-nav {
    transform: translateY(100%);
}

/* 表格横向滚动容器（JS 会在渲染后将 table 包入 .table-wrap） */
.table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -16px;
    padding: 0 16px;
}
.table-wrap .editable-table,
.table-wrap .data-table {
    min-width: 600px;
}

/* 移动端底部步骤导航（桌面端默认隐藏） */
.mobile-step-nav {
    display: none;
}

@media (max-width: 600px) {
    .navbar {
        padding: 0 max(12px, env(safe-area-inset-left)) 0 max(12px, env(safe-area-inset-right));
    }
    .nav-brand .brand-text {
        font-size: 14px;
    }
    .nav-brand .brand-version {
        display: none;
    }
    .nav-links {
        gap: 14px;
    }
    .nav-links a {
        font-size: 13px;
    }
    .nav-user {
        gap: 8px;
    }
    .nav-login-btn,
    .nav-logout-btn,
    .nav-user-name {
        font-size: 12px;
    }

    .main-container {
        padding-top: 60px;
    }

    .search-section {
        min-height: calc(100vh - 60px);
        min-height: calc(100dvh - 60px);
        padding: 24px 16px;
    }

    .search-title {
        font-size: 24px;
    }

    .model-selector {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .model-card {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        min-width: auto;
        width: 100%;
        padding: 12px 16px;
    }
    .model-name {
        margin-bottom: 0;
    }
    .model-desc {
        display: none;
    }

    .search-form input,
    .search-form textarea,
    .hint-row input,
    .solutions-search input,
    .login-form input[type="text"],
    .login-form input[type="password"] {
        font-size: 16px;
    }

    .form-actions {
        flex-direction: column;
        align-items: stretch;
    }
    .form-actions .btn-primary,
    .form-actions .btn-outline {
        width: 100%;
        justify-content: center;
    }

    .btn-primary,
    .btn-outline,
    .btn-confirm,
    .btn-reject,
    .btn-confirm-jobs,
    .upload-dropzone,
    .upload-item-delete,
    .mobile-step-item {
        min-height: 44px;
        min-width: 44px;
    }

    .upload-dropzone {
        padding: 32px 16px;
        min-height: 120px;
    }

    .dashboard-section {
        padding: 16px;
        padding-bottom: calc(56px + env(safe-area-inset-bottom, 0));
    }

    .company-header {
        padding: 16px;
        gap: 12px;
    }
    .company-info h2 {
        font-size: 20px;
    }
    .company-meta {
        flex-wrap: wrap;
    }
    .company-actions {
        width: 100%;
        justify-content: flex-start;
    }

    /* 隐藏顶部步骤导航，使用底部固定导航 */
    .step-nav {
        display: none;
    }
    .mobile-step-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 110;
        background: var(--bg-card);
        border-top: 1px solid var(--border);
        box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
        padding-bottom: env(safe-area-inset-bottom, 0);
        transition: transform 0.25s ease;
    }
    .mobile-step-nav.hidden {
        display: none !important;
    }
    .mobile-step-item {
        flex: 1;
        min-height: 56px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        font-size: 11px;
        color: var(--text-light);
        cursor: pointer;
        transition: var(--transition);
        border-top: 2px solid transparent;
    }
    .mobile-step-item.active {
        color: var(--primary);
        border-top-color: var(--accent);
        background: var(--amber-bg);
    }
    .mobile-step-item.completed {
        color: var(--green);
        background: var(--green-bg);
    }
    .mobile-step-item.pending {
        color: var(--text-light);
    }
    .mobile-step-num {
        width: 20px;
        height: 20px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 10px;
        font-weight: 700;
        background: currentColor;
        opacity: 0.15;
    }
    .mobile-step-item.active .mobile-step-num {
        background: var(--accent);
        color: var(--primary);
        opacity: 1;
    }
    .mobile-step-item.completed .mobile-step-num {
        background: var(--green);
        color: var(--text-white);
        opacity: 1;
    }
    .mobile-step-label {
        font-size: 10px;
        line-height: 1.2;
    }

    .step-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
        padding: 14px 16px;
    }
    .step-subtitle {
        margin-left: 0;
    }
    .step-regen-btn {
        margin-left: 0;
    }

    .editable-content {
        padding: 16px;
        overflow-x: auto;
    }

    .modal {
        align-items: flex-end;
        padding: 0;
    }
    .modal-content {
        width: 100%;
        max-width: 100% !important;
        height: 92vh;
        height: 92dvh;
        max-height: none;
        border-radius: 16px 16px 0 0;
        padding-bottom: env(safe-area-inset-bottom, 0);
    }
    .modal-header {
        padding: 16px 20px;
    }
    .modal-body {
        padding: 16px 20px;
    }
    .modal-footer {
        padding: 12px 20px;
    }

    .loading-stream,
    .loading-sections {
        width: 95%;
        max-height: 25vh;
    }

    .solutions-section {
        padding: 16px;
        padding-bottom: calc(56px + env(safe-area-inset-bottom, 0));
    }
    body.no-mobile-nav .dashboard-section,
    body.no-mobile-nav .solutions-section {
        padding-bottom: 16px;
    }
    .solutions-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    .solutions-search {
        width: 100%;
    }
    .solutions-search input {
        width: 100%;
    }
}

@media (max-width: 400px) {
    .search-title {
        font-size: 22px;
    }
    .dashboard-section,
    .solutions-section {
        padding: 12px;
        padding-bottom: calc(56px + env(safe-area-inset-bottom, 0));
    }
    body.no-mobile-nav .dashboard-section,
    body.no-mobile-nav .solutions-section {
        padding-bottom: 12px;
    }
    .nav-brand .brand-text {
        font-size: 12px;
    }
    .nav-links {
        gap: 10px;
    }
    .nav-links a {
        font-size: 12px;
    }
    .nav-login-btn,
    .nav-logout-btn,
    .nav-user-name {
        font-size: 11px;
    }
    .mobile-step-label {
        font-size: 9px;
    }
}

/* ========== 导航栏用户区域 ========== */
.nav-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-login-btn {
    color: var(--accent);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
}

.nav-login-btn:hover {
    color: var(--text-white);
}

.nav-user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-user-name {
    color: var(--accent);
    font-size: 13px;
    font-weight: 500;
}

.nav-logout-btn {
    color: rgba(255,255,255,0.5);
    font-size: 12px;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
}

.nav-logout-btn:hover {
    color: var(--text-white);
}

/* ========== 登录弹窗 ========== */
.login-form {
    margin: 0;
    padding: 0;
}

.login-form .form-group {
    margin-bottom: 14px;
}

.form-label-dark {
    display: block;
    color: var(--text);
    font-size: 13px;
    margin-bottom: 4px;
    font-weight: 500;
}

.login-form input[type="text"],
.login-form input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: 14px;
    outline: none;
    transition: var(--transition);
}

.login-form input:focus {
    border-color: var(--accent);
}

.login-error {
    color: var(--red);
    font-size: 12px;
    text-align: center;
    margin-top: 8px;
}

/* ========== 方案库 ========== */
.solutions-section {
    padding: 32px;
    max-width: 1200px;
    margin: 0 auto;
    animation: fadeIn 0.3s ease;
}

.solutions-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    gap: 16px;
    flex-wrap: wrap;
}

.solutions-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

.solutions-search {
    display: flex;
    gap: 8px;
}

.solutions-search input {
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 13px;
    width: 240px;
    outline: none;
}

.solutions-search input:focus {
    border-color: var(--accent);
}

.solutions-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 16px;
}

.solution-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.solution-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.solution-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.solution-company {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
}

.solution-industry {
    font-size: 11px;
    color: var(--text-light);
    background: var(--bg);
    padding: 2px 8px;
    border-radius: 10px;
}

.solution-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.solution-tag {
    font-size: 11px;
    color: var(--text-light);
    background: var(--bg);
    padding: 2px 8px;
    border-radius: 4px;
}

.solution-card-progress {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
}

.solution-progress-label {
    font-size: 11px;
    color: var(--text-light);
}

.sol-step-badge {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
}

.sol-step-done {
    background: var(--green);
    color: var(--text-white);
}

.sol-step-partial {
    background: var(--amber-bg);
    color: var(--accent);
    border: 1px solid var(--accent);
}

.sol-step-empty {
    background: var(--bg);
    color: var(--text-light);
    border: 1px solid var(--border);
}

.solution-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.solution-date {
    font-size: 11px;
    color: var(--text-light);
}

.solutions-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
    font-size: 13px;
    color: var(--text-light);
}
