/**
 * 泽盛赋能 AI 集合平台 - 深海科技风格
 * PHP 版本样式表
 */

/* ============ CSS 变量 ============ */
:root {
    --bg: oklch(0.13 0.025 250);
    --bg-secondary: oklch(0.12 0.025 250);
    --foreground: oklch(0.92 0.01 220);
    --foreground-muted: oklch(0.65 0.02 220);
    --primary: oklch(0.72 0.15 200);
    --primary-fg: oklch(0.13 0.025 250);
    --secondary: oklch(0.22 0.02 250);
    --secondary-fg: oklch(0.85 0.01 220);
    --accent: oklch(0.75 0.14 75);
    --accent-fg: oklch(0.13 0.025 250);
    --destructive: oklch(0.60 0.22 25);
    --border: oklch(0.28 0.025 250);
    --input: oklch(0.22 0.02 250);
    --muted: oklch(0.20 0.015 250);
    --radius: 0.625rem;
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans SC", sans-serif;
    --font-mono: "JetBrains Mono", "Fira Code", "Cascadia Code", monospace;
}

/* ============ Reset & Base ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--foreground);
    line-height: 1.5;
    overflow: hidden;
    height: 100vh;
}
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
input, textarea, select { font-family: inherit; }
a { color: var(--primary); text-decoration: none; }

/* ============ 滚动条 ============ */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: oklch(0.35 0.02 250); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: oklch(0.45 0.02 250); }

/* ============ 通用组件 ============ */
.glass-card {
    background: oklch(0.17 0.02 250 / 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid oklch(0.35 0.03 250 / 0.3);
    border-radius: var(--radius);
    overflow: hidden;
}
.glow-border {
    box-shadow: 0 0 0 1px oklch(0.72 0.15 200 / 0.15), 0 0 15px oklch(0.72 0.15 200 / 0.08);
}
.glow-border:hover {
    box-shadow: 0 0 0 1px oklch(0.72 0.15 200 / 0.3), 0 0 20px oklch(0.72 0.15 200 / 0.15);
}
.pulse-dot {
    display: inline-block;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--primary);
    animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
.spin { animation: spin 1s linear infinite; }

/* ============ 按钮 ============ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
}
.btn svg { width: 14px; height: 14px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary {
    background: var(--primary);
    color: var(--primary-fg);
}
.btn-primary:hover:not(:disabled) { filter: brightness(1.1); }
.btn-primary-outline {
    background: oklch(0.72 0.15 200 / 0.2);
    color: var(--primary);
    border: 1px solid oklch(0.72 0.15 200 / 0.3);
}
.btn-primary-outline:hover:not(:disabled) { background: oklch(0.72 0.15 200 / 0.3); }
.btn-secondary {
    background: oklch(0.22 0.02 250 / 0.6);
    color: var(--foreground);
    border: 1px solid oklch(0.28 0.025 250 / 0.3);
}
.btn-secondary:hover:not(:disabled) { background: var(--secondary); }
.btn-accent {
    background: oklch(0.75 0.14 75 / 0.8);
    color: var(--accent-fg);
    border: 1px solid oklch(0.75 0.14 75 / 0.5);
    box-shadow: 0 0 12px oklch(0.75 0.14 75 / 0.2);
}
.btn-accent:hover:not(:disabled) { background: var(--accent); }
.btn-icon {
    padding: 6px;
    border-radius: 6px;
    background: oklch(0.22 0.02 250 / 0.6);
    border: 1px solid oklch(0.28 0.025 250 / 0.3);
}
.btn-icon:hover { background: var(--secondary); }
.btn-icon svg { width: 14px; height: 14px; }
.btn-sm { padding: 4px 12px; font-size: 11px; }
.btn-sm svg { width: 12px; height: 12px; }
.btn-text {
    padding: 4px 8px;
    font-size: 12px;
    color: var(--foreground-muted);
}
.btn-text:hover { color: var(--primary); }
.btn-text svg { width: 12px; height: 12px; }

/* ============ 输入框 ============ */
.input-field {
    width: 100%;
    background: var(--input);
    border: 1px solid oklch(0.28 0.025 250 / 0.3);
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    color: var(--foreground);
    outline: none;
    transition: border-color 0.2s;
}
.input-field:focus {
    border-color: oklch(0.72 0.15 200 / 0.5);
    box-shadow: 0 0 0 2px oklch(0.72 0.15 200 / 0.1);
}
.input-field::placeholder { color: oklch(0.5 0.02 250); }
.input-sm { padding: 4px 10px; font-size: 11px; }

/* ============ Toggle Switch ============ */
.toggle-switch { position: relative; display: inline-block; width: 36px; height: 20px; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
    position: absolute; inset: 0;
    background: oklch(0.3 0.02 250);
    border-radius: 20px;
    transition: 0.3s;
    cursor: pointer;
}
.toggle-slider::before {
    content: '';
    position: absolute;
    width: 16px; height: 16px;
    left: 2px; bottom: 2px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
}
.toggle-switch input:checked + .toggle-slider { background: var(--primary); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(16px); }

/* ============ Checkbox ============ */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 12px;
    color: var(--foreground-muted);
}
.checkbox-label input[type="checkbox"] {
    width: 14px; height: 14px;
    border-radius: 3px;
    border: 1px solid oklch(0.35 0.025 250 / 0.5);
    background: var(--input);
    accent-color: var(--primary);
}

/* ============ App 布局 ============ */
.app-layout {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

/* ============ 顶部导航 ============ */
.top-nav {
    height: 40px;
    display: flex;
    align-items: center;
    padding: 0 12px;
    gap: 2px;
    border-bottom: 1px solid oklch(0.28 0.025 250 / 0.5);
    background: oklch(0.12 0.025 250 / 0.8);
    backdrop-filter: blur(12px);
    position: relative;
    z-index: 50;
    flex-shrink: 0;
}
.nav-brand {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-right: 12px;
    flex-shrink: 0;
}
.brand-icon { width: 16px; height: 16px; color: var(--primary); }
.brand-name {
    font-family: serif;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.05em;
}
.brand-version {
    font-size: 9px;
    color: var(--foreground-muted);
    background: var(--secondary);
    padding: 2px 4px;
    border-radius: 4px;
    font-family: var(--font-mono);
}
.nav-left, .nav-right { display: flex; align-items: center; gap: 2px; }
.nav-spacer { flex: 1; }
.nav-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    color: var(--foreground-muted);
    transition: all 0.2s;
}
.nav-btn:hover { color: var(--foreground); background: oklch(0.22 0.02 250 / 0.6); }
.nav-btn.active { background: oklch(0.72 0.15 200 / 0.15); color: var(--primary); }
.nav-btn svg { width: 12px; height: 12px; }
.nav-label { display: none; }
.nav-label-md { display: none; }
@media (min-width: 640px) { .nav-label { display: inline; } }
@media (min-width: 768px) { .nav-label-md { display: inline; } }
.nav-glow-line {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(to right, transparent, oklch(0.72 0.15 200 / 0.3), transparent);
}

/* ============ 主内容区 ============ */
.main-content {
    flex: 1;
    display: flex;
    overflow: hidden;
}
.workspace-view {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* ============ 模型面板（左侧） ============ */
.model-panel {
    width: 200px;
    min-width: 200px;
    border-right: 1px solid oklch(0.28 0.025 250 / 0.5);
    display: flex;
    flex-direction: column;
    background: oklch(0.12 0.02 250 / 0.5);
}
.panel-header {
    padding: 10px 12px;
    border-bottom: 1px solid oklch(0.28 0.025 250 / 0.3);
}
.panel-header h2 {
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}
.panel-header h2 svg { width: 14px; height: 14px; color: var(--primary); }
.model-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* 模型卡片 */
.model-card {
    border-radius: 8px;
    padding: 8px;
    transition: all 0.2s;
    cursor: pointer;
    background: oklch(0.22 0.02 250 / 0.2);
    border: 1px solid oklch(0.28 0.025 250 / 0.15);
}
.model-card:hover { border-color: oklch(0.28 0.025 250 / 0.3); }
.model-card.connected {
    background: oklch(0.17 0.02 250 / 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid oklch(0.35 0.03 250 / 0.3);
    box-shadow: 0 0 0 1px oklch(0.72 0.15 200 / 0.15), 0 0 15px oklch(0.72 0.15 200 / 0.08);
}
.model-card.active {
    background: oklch(0.72 0.15 200 / 0.1);
    border: 1px solid oklch(0.72 0.15 200 / 0.3);
    box-shadow: 0 0 12px oklch(0.55 0.2 250 / 0.15);
}
.model-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}
.model-number {
    font-size: 10px;
    color: var(--foreground-muted);
    font-family: var(--font-mono);
}
.model-status-badges {
    display: flex;
    align-items: center;
    gap: 4px;
}
.node-badge {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 9px;
    color: oklch(0.7 0.2 145);
    background: oklch(0.5 0.2 145 / 0.1);
    padding: 2px 4px;
    border-radius: 4px;
}
.node-badge svg { width: 10px; height: 10px; }
.connected-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: oklch(0.7 0.2 145);
    box-shadow: 0 0 6px oklch(0.7 0.2 145);
}
.model-url-row {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 6px;
}
.url-edit-icon { width: 10px; height: 10px; color: oklch(0.5 0.02 250 / 0.4); flex-shrink: 0; }
.model-url-input {
    width: 100%;
    background: transparent;
    border: none;
    font-size: 10px;
    color: oklch(0.85 0.01 220 / 0.8);
    outline: none;
    padding: 0;
}
.model-url-input::placeholder { color: oklch(0.5 0.02 250 / 0.4); }
.model-connect-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 6px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 500;
    transition: all 0.2s;
    background: oklch(0.2 0.015 250 / 0.3);
    color: oklch(0.5 0.02 250 / 0.5);
    border: 1px solid oklch(0.28 0.025 250 / 0.15);
}
.model-connect-btn:disabled { cursor: not-allowed; }
.model-connect-btn svg { width: 12px; height: 12px; }
.model-connect-btn.has-url {
    background: oklch(0.75 0.14 75 / 0.8);
    color: var(--accent-fg);
    border: 1px solid oklch(0.75 0.14 75 / 0.5);
    box-shadow: 0 0 8px oklch(0.75 0.14 75 / 0.15);
    cursor: pointer;
}
.model-connect-btn.has-url:hover { background: var(--accent); }
.model-connect-btn.is-connected {
    background: oklch(0.5 0.22 25 / 0.15);
    color: oklch(0.7 0.2 25);
    border: 1px solid oklch(0.5 0.22 25 / 0.2);
    cursor: pointer;
}
.model-connect-btn.is-connected:hover { background: oklch(0.5 0.22 25 / 0.25); }
.model-connect-btn.loading {
    background: oklch(0.22 0.02 250 / 0.6);
    color: var(--foreground-muted);
    cursor: wait;
}

/* ============ 参数面板（中间） ============ */
.params-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    border-right: 1px solid oklch(0.28 0.025 250 / 0.5);
    background: oklch(0.12 0.02 250 / 0.5);
    min-width: 0;
}
.params-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.params-header-actions { display: flex; align-items: center; gap: 8px; }
.model-info-badge {
    font-size: 10px;
    color: var(--primary);
    background: oklch(0.72 0.15 200 / 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid oklch(0.72 0.15 200 / 0.2);
}
.params-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}
.params-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 8px;
    color: var(--foreground-muted);
}
.empty-icon { width: 48px; height: 48px; opacity: 0.3; }
.params-empty p { font-size: 13px; }
.params-empty .empty-sub { font-size: 11px; opacity: 0.6; }
.params-form { display: flex; flex-direction: column; gap: 12px; }
.param-group {
    background: oklch(0.17 0.02 250 / 0.4);
    border: 1px solid oklch(0.28 0.025 250 / 0.2);
    border-radius: 8px;
    padding: 12px;
}
.param-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}
.param-label-text {
    font-size: 11px;
    font-weight: 500;
    color: var(--foreground);
}
.param-label-type {
    font-size: 9px;
    color: var(--foreground-muted);
    background: oklch(0.22 0.02 250 / 0.6);
    padding: 1px 6px;
    border-radius: 4px;
    font-family: var(--font-mono);
}
.param-input {
    width: 100%;
    background: var(--input);
    border: 1px solid oklch(0.28 0.025 250 / 0.3);
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 12px;
    color: var(--foreground);
    outline: none;
    transition: border-color 0.2s;
}
.param-input:focus {
    border-color: oklch(0.72 0.15 200 / 0.5);
    box-shadow: 0 0 0 2px oklch(0.72 0.15 200 / 0.1);
}
.param-input::placeholder { color: oklch(0.5 0.02 250 / 0.5); }
textarea.param-input { resize: vertical; min-height: 60px; }
select.param-input { cursor: pointer; }
.param-upload {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.upload-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 20px;
    border: 2px dashed oklch(0.28 0.025 250 / 0.4);
    border-radius: 8px;
    color: var(--foreground-muted);
    font-size: 11px;
    transition: all 0.2s;
    cursor: pointer;
    background: transparent;
    width: 100%;
}
.upload-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: oklch(0.72 0.15 200 / 0.05);
}
.upload-btn svg { width: 16px; height: 16px; }
.upload-result {
    font-size: 9px;
    color: oklch(0.72 0.15 200 / 0.7);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.params-actions {
    padding: 10px 16px;
    border-top: 1px solid oklch(0.28 0.025 250 / 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

/* ============ 历史记录面板（右侧） ============ */
.history-panel {
    width: 280px;
    min-width: 280px;
    display: flex;
    flex-direction: column;
    background: oklch(0.12 0.02 250 / 0.5);
}
.history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.history-tabs { display: flex; gap: 2px; }
.tab-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    color: var(--foreground-muted);
    transition: all 0.2s;
}
.tab-btn:hover { color: var(--foreground); background: oklch(0.22 0.02 250 / 0.4); }
.tab-btn.active { background: oklch(0.72 0.15 200 / 0.15); color: var(--primary); }
.tab-btn svg { width: 12px; height: 12px; }
.history-body {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
}
.history-list { display: flex; flex-direction: column; gap: 6px; }
.history-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 16px;
    gap: 8px;
    color: var(--foreground-muted);
}
.history-empty .empty-icon { width: 32px; height: 32px; opacity: 0.3; }
.history-empty p { font-size: 12px; }
.history-empty .empty-sub { font-size: 10px; opacity: 0.6; }

/* 历史记录卡片 */
.history-card {
    background: oklch(0.17 0.02 250 / 0.4);
    border: 1px solid oklch(0.28 0.025 250 / 0.2);
    border-radius: 8px;
    padding: 10px;
    transition: all 0.2s;
}
.history-card:hover { border-color: oklch(0.28 0.025 250 / 0.4); }
.history-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}
.history-model-name { font-size: 11px; font-weight: 500; color: var(--foreground); }
.history-status {
    font-size: 9px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}
.history-status.running { background: oklch(0.72 0.15 200 / 0.15); color: var(--primary); }
.history-status.completed { background: oklch(0.5 0.2 145 / 0.15); color: oklch(0.7 0.2 145); }
.history-status.failed { background: oklch(0.5 0.22 25 / 0.15); color: oklch(0.7 0.2 25); }
.history-time { font-size: 9px; color: var(--foreground-muted); font-family: var(--font-mono); }
.history-result {
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid oklch(0.28 0.025 250 / 0.15);
}
.history-result-item {
    margin-top: 4px;
}
.history-result-item img, .history-result-item video {
    max-width: 100%;
    border-radius: 6px;
    border: 1px solid oklch(0.28 0.025 250 / 0.3);
}
.history-result-item a {
    font-size: 10px;
    color: var(--primary);
    word-break: break-all;
}

/* ============ 底部状态栏 ============ */
.status-bar {
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    border-top: 1px solid oklch(0.28 0.025 250 / 0.3);
    background: oklch(0.10 0.02 250 / 0.8);
    font-size: 10px;
    color: var(--foreground-muted);
    flex-shrink: 0;
}
.status-time { font-family: var(--font-mono); flex-shrink: 0; margin-left: 16px; }

/* ============ 工具箱 ============ */
.toolbox-view {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
}
.toolbox-container { max-width: 900px; margin: 0 auto; }
.toolbox-title {
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
}
.toolbox-title svg { width: 20px; height: 20px; color: var(--primary); }
.toolbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 16px;
}
.tool-card {
    background: oklch(0.17 0.02 250 / 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid oklch(0.35 0.03 250 / 0.3);
    border-radius: var(--radius);
    padding: 20px;
    text-align: left;
    transition: all 0.3s;
    width: 100%;
}
.tool-card:hover { border-color: oklch(0.72 0.15 200 / 0.3); }
.tool-card-disabled { opacity: 0.6; cursor: default; }
.tool-icon {
    width: 64px; height: 64px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    transition: transform 0.3s;
}
.tool-card:hover .tool-icon { transform: scale(1.05); }
.tool-icon span { font-size: 32px; }
.tool-icon svg { width: 32px; height: 32px; }
.tool-icon-yellow { background: linear-gradient(135deg, oklch(0.8 0.15 85 / 0.2), oklch(0.75 0.14 75 / 0.1)); }
.tool-icon-purple { background: linear-gradient(135deg, oklch(0.6 0.2 300 / 0.2), oklch(0.65 0.18 330 / 0.1)); color: oklch(0.7 0.15 300); }
.tool-icon-muted { background: linear-gradient(135deg, oklch(0.2 0.015 250 / 0.3), oklch(0.2 0.015 250 / 0.1)); color: oklch(0.5 0.02 250 / 0.4); }
.tool-card h3 { font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.tool-card p { font-size: 11px; color: var(--foreground-muted); line-height: 1.6; }

/* ============ 弹窗 ============ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: oklch(0 0 0 / 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    padding: 16px;
}
.modal-container {
    background: oklch(0.15 0.025 250);
    border: 1px solid oklch(0.28 0.025 250 / 0.5);
    border-radius: 12px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px oklch(0 0 0 / 0.4);
}
.disclaimer-modal { max-width: 520px; }
.about-modal { max-width: 480px; }
.personal-modal { max-width: 600px; }
.modal-header {
    padding: 24px 24px 16px;
    text-align: center;
    position: relative;
}
.modal-header-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    background: oklch(0.72 0.15 200 / 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}
.modal-header-icon svg { width: 24px; height: 24px; color: var(--primary); }
.modal-header h2 { font-size: 18px; font-weight: 600; margin-bottom: 4px; }
.modal-subtitle { font-size: 12px; color: var(--foreground-muted); }
.modal-close {
    position: absolute;
    top: 16px; right: 16px;
    padding: 4px;
    border-radius: 6px;
    color: var(--foreground-muted);
    transition: all 0.2s;
}
.modal-close:hover { color: var(--foreground); background: oklch(0.22 0.02 250 / 0.6); }
.modal-close svg { width: 16px; height: 16px; }
.modal-body {
    padding: 0 24px;
    overflow-y: auto;
    flex: 1;
}
.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid oklch(0.28 0.025 250 / 0.3);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

/* 免责声明 */
.disclaimer-body { display: flex; flex-direction: column; gap: 12px; padding-bottom: 16px; }
.disclaimer-section {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: oklch(0.17 0.02 250 / 0.4);
    border: 1px solid oklch(0.28 0.025 250 / 0.2);
    border-radius: 8px;
}
.disclaimer-icon { flex-shrink: 0; }
.disclaimer-icon svg { width: 16px; height: 16px; color: var(--accent); }
.disclaimer-section h4 { font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.disclaimer-section p { font-size: 11px; color: var(--foreground-muted); line-height: 1.6; }
.disclaimer-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    cursor: pointer;
    flex: 1;
}
.disclaimer-checkbox input { accent-color: var(--primary); width: 16px; height: 16px; }

/* 关于我们 */
.about-body { padding-bottom: 16px; }
.about-desc { font-size: 12px; color: var(--foreground-muted); line-height: 1.8; margin-bottom: 16px; }
.about-links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 16px; }
.about-link-card {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 12px;
    background: oklch(0.17 0.02 250 / 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid oklch(0.35 0.03 250 / 0.3);
    border-radius: var(--radius);
    transition: all 0.2s;
    cursor: pointer;
}
.about-link-card:hover { border-color: oklch(0.72 0.15 200 / 0.3); }
.about-link-card svg { width: 16px; height: 16px; color: var(--foreground-muted); flex-shrink: 0; margin-top: 2px; }
.link-title { font-size: 12px; font-weight: 500; }
.link-desc { font-size: 10px; color: var(--foreground-muted); }
.about-tip { font-size: 12px; color: var(--foreground-muted); text-align: center; }

/* 个人中心 */
.personal-body { display: flex; flex-direction: column; gap: 16px; padding-bottom: 16px; }
.personal-section { display: flex; flex-direction: column; gap: 8px; }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.section-title { display: flex; align-items: center; gap: 8px; }
.section-title svg { width: 16px; height: 16px; color: var(--primary); }
.section-title h4 { font-size: 13px; font-weight: 600; }
.section-actions { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 200px; }
.section-actions .input-field { flex: 1; }
.key-actions-row { display: flex; align-items: center; justify-content: space-between; }
.table-header { padding: 10px 16px; border-bottom: 1px solid oklch(0.28 0.025 250 / 0.2); }
.table-header h4 { font-size: 12px; font-weight: 500; }
.table-wrapper { overflow-x: auto; }
.data-table { width: 100%; font-size: 12px; border-collapse: collapse; }
.data-table th {
    padding: 8px 16px;
    text-align: left;
    font-weight: 500;
    color: var(--foreground-muted);
    border-bottom: 1px solid oklch(0.28 0.025 250 / 0.2);
}
.data-table th.text-right { text-align: right; }
.data-table td {
    padding: 8px 16px;
    color: var(--foreground-muted);
    border-bottom: 1px solid oklch(0.28 0.025 250 / 0.1);
}
.data-table td:first-child { color: var(--foreground); font-family: var(--font-mono); }
.data-table td.text-right { text-align: right; }
.data-table tr:last-child td { border-bottom: none; }
.auto-save-card { padding: 16px; }
.auto-save-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.auto-save-title { display: flex; align-items: center; gap: 8px; }
.auto-save-title svg { width: 16px; height: 16px; color: var(--primary); }
.auto-save-title h4 { font-size: 12px; font-weight: 500; }
.auto-save-dir { display: flex; gap: 8px; align-items: center; }
.dir-path {
    flex: 1;
    font-size: 12px;
    color: var(--foreground-muted);
    background: oklch(0.22 0.02 250 / 0.5);
    border-radius: 6px;
    padding: 6px 12px;
    border: 1px solid oklch(0.28 0.025 250 / 0.2);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ============ Toast 通知 ============ */
.toast-container {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 200;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}
.toast {
    background: oklch(0.17 0.02 250);
    border: 1px solid oklch(0.25 0.02 250);
    color: oklch(0.9 0.01 250);
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 13px;
    pointer-events: auto;
    animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
    box-shadow: 0 8px 24px oklch(0 0 0 / 0.3);
    max-width: 400px;
}
.toast.success { border-left: 3px solid oklch(0.7 0.2 145); }
.toast.error { border-left: 3px solid oklch(0.6 0.22 25); }
.toast.info { border-left: 3px solid var(--primary); }
.toast-desc { font-size: 11px; color: var(--foreground-muted); margin-top: 4px; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes toastOut { from { opacity: 1; } to { opacity: 0; transform: translateY(-10px); } }

/* ============ 响应式 ============ */
@media (max-width: 768px) {
    .model-panel { width: 160px; min-width: 160px; }
    .history-panel { width: 220px; min-width: 220px; }
}
@media (max-width: 640px) {
    .workspace-view { flex-direction: column; }
    .model-panel { width: 100%; min-width: auto; max-height: 200px; border-right: none; border-bottom: 1px solid oklch(0.28 0.025 250 / 0.5); }
    .model-list { flex-direction: row; overflow-x: auto; overflow-y: hidden; }
    .model-card { min-width: 160px; }
    .history-panel { width: 100%; min-width: auto; max-height: 200px; border-top: 1px solid oklch(0.28 0.025 250 / 0.5); }
    .params-panel { border-right: none; }
}
