:root {
    --primary: #667eea; --primary-dark: #5a67d8; --primary-light: #e8eaf6;
    --secondary: #764ba2; --success: #48bb78; --success-light: #e8f5e9;
    --warning: #ed8936; --warning-light: #fff8e1; --danger: #f56565; --danger-light: #fff5f5;
    --text-primary: #2d3748; --text-secondary: #718096; --text-muted: #a0aec0;
    --bg-body: #f7f8fc; --bg-card: #ffffff; --border: #e8ecf1;
    --sidebar-width: 240px; --radius: 12px; --radius-sm: 8px;
    --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.04);
    --shadow-lg: 0 4px 20px rgba(0,0,0,0.08); --transition: all 0.2s ease;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif; background: var(--bg-body); color: var(--text-primary); line-height: 1.6; min-height: 100vh; }
a { text-decoration: none; color: var(--primary); } a:hover { color: var(--primary-dark); }

/* Sidebar */
.sidebar { position: fixed; left: 0; top: 0; width: var(--sidebar-width); height: 100vh; background: linear-gradient(180deg, #1a1f36 0%, #2d3250 100%); color: #fff; display: flex; flex-direction: column; z-index: 100; box-shadow: 2px 0 20px rgba(0,0,0,0.1); }
.sidebar-header { padding: 24px 20px 16px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon { font-size: 28px; width: 40px; height: 40px; min-width: 40px; border-radius: 8px; overflow: visible; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.logo-icon .logo-emoji { font-size: 28px; line-height: 1; }
.logo-icon .logo-img { width: auto !important; height: 40px !important; max-width: 180px; object-fit: contain; display: block; background: transparent; padding: 0; border-radius: 6px; }
.logo:has(.logo-img) .logo-icon { width: auto; height: 40px; min-width: 0; overflow: visible; }
.logo:has(.logo-img) .logo-text { display: none; }
.message-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 50%; }
.preview-logo { width: 72px; height: 72px; margin: 0 auto 8px; display: flex; align-items: center; justify-content: center; border-radius: 16px; background: #f7f7fb; font-size: 40px; line-height: 1; overflow: hidden; }
.preview-logo img { width: 100% !important; height: 100% !important; object-fit: contain !important; padding: 6px; box-sizing: border-box; }
.logo-uploaded-tag { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; background: #eef0ff; color: #6c5ce7; border-radius: 8px; font-size: 13px; font-weight: 500; }
.logo-uploaded-tag img { width: 22px; height: 22px; object-fit: contain; border-radius: 4px; background: #fff; } .logo-text { font-size: 18px; font-weight: 700; }
.sidebar-user { padding: 20px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.user-avatar { width: 40px; height: 40px; border-radius: 10px; background: linear-gradient(135deg, var(--primary), var(--secondary)); display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 16px; }
.user-name { font-size: 14px; font-weight: 600; } .user-type { font-size: 11px; opacity: 0.6; }
.sidebar-nav { list-style: none; padding: 12px; flex: 1; }
.nav-item { margin-bottom: 4px; }
.nav-link { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: var(--radius-sm); color: rgba(255,255,255,0.65); font-size: 14px; font-weight: 500; transition: var(--transition); cursor: pointer; text-decoration: none; }
.nav-link:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-link.active { background: linear-gradient(135deg, var(--primary), var(--secondary)); color: #fff; box-shadow: 0 4px 12px rgba(102,126,234,0.4); }
.nav-icon { font-size: 18px; }
.sidebar-footer { padding: 12px 16px 20px; border-top: 1px solid rgba(255,255,255,0.08); }
.logout-btn { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: var(--radius-sm); color: rgba(255,255,255,0.5); font-size: 14px; cursor: pointer; text-decoration: none; transition: var(--transition); }
.logout-btn:hover { color: #fff; background: rgba(255,255,255,0.08); }

/* Main */
.main-content { margin-left: var(--sidebar-width); padding: 32px 40px; min-height: 100vh; }

/* Page Header */
.page-header { margin-bottom: 28px; }
.page-header h1 { font-size: 26px; font-weight: 700; } .page-header p { font-size: 14px; color: var(--text-secondary); margin-top: 4px; }
.page-header-logo { width: 64px; height: 64px; border-radius: 16px; overflow: hidden; background: var(--brand-primary, var(--primary)); display: flex; align-items: center; justify-content: center; font-size: 32px; box-shadow: 0 4px 12px rgba(0,0,0,0.1); flex-shrink: 0; }
.page-header-logo .logo-emoji { font-size: 32px; }
.page-header-logo .logo-img { width: 100%; height: 100%; object-fit: contain; padding: 4px; box-sizing: border-box; background: #fff; border-radius: 12px; }

/* Banners */
.banner { display: flex; align-items: center; gap: 14px; padding: 16px 20px; border-radius: var(--radius); margin-bottom: 24px; font-size: 14px; }
.banner-expired { background: var(--danger-light); border: 1px solid #fed7d7; color: #c53030; }
.banner-trial-warning { background: var(--warning-light); border: 1px solid #fbd38d; color: #c05621; }
.banner-info { background: linear-gradient(135deg, #ebf4ff 0%, #e8eaf6 100%); border: 1px solid #bee3f8; color: #2b6cb0; }
.banner-icon { font-size: 20px; flex-shrink: 0; } .banner-content { flex: 1; }
.banner-action { padding: 6px 16px; border-radius: 20px; font-size: 13px; font-weight: 500; background: #fff; border: 1px solid currentColor; color: inherit; white-space: nowrap; cursor: pointer; }

/* Package Card */
.package-card { display: flex; align-items: center; justify-content: space-between; padding: 24px; background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 24px; }
.package-info { display: flex; align-items: center; gap: 16px; }
.package-badge { padding: 6px 18px; border-radius: 20px; font-size: 13px; font-weight: 600; }
.package-badge-trial { background: #ebf4ff; color: #3182ce; }
.package-badge-basic { background: #e8f5e9; color: #2e7d32; }
.package-badge-pro { background: #f3e8ff; color: #7c3aed; }
.package-badge-flagship { background: #fff7ed; color: #c2410c; }
.package-details h3 { font-size: 16px; font-weight: 600; } .package-details p { font-size: 13px; color: var(--text-secondary); margin-top: 2px; }
.btn-upgrade { background: linear-gradient(135deg, var(--primary), var(--secondary)); color: #fff; padding: 8px 20px; border-radius: 20px; font-size: 13px; font-weight: 600; border: none; cursor: pointer; }

/* Stats */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 32px; }
.stat-card { background: var(--bg-card); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); display: flex; align-items: flex-start; gap: 14px; transition: var(--transition); }
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.stat-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.stat-icon-conversation { background: #ebf4ff; } .stat-icon-copy { background: #f0fff4; } .stat-icon-days { background: #fffbeb; } .stat-icon-status { background: #e8f5e9; }
.stat-value { font-size: 28px; font-weight: 700; line-height: 1.1; } .stat-label { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }

/* Quick Actions */
.section-title { font-size: 18px; font-weight: 600; margin-bottom: 16px; }
.actions-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.action-card { display: flex; align-items: center; gap: 16px; padding: 24px; background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); transition: var(--transition); cursor: pointer; border: 1px solid transparent; text-decoration: none; color: inherit; }
.action-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: var(--primary); color: inherit; }
.action-icon { font-size: 36px; } .action-info h3 { font-size: 16px; font-weight: 600; } .action-info p { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.action-arrow { margin-left: auto; font-size: 20px; color: var(--text-muted); }

/* Chat Page */
.chat-container { display: flex; height: calc(100vh - 96px); background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; max-width: 100%; }
.chat-main { flex: 1; display: flex; flex-direction: column; }
.chat-header { padding: 16px 24px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; }
.chat-header h2 { font-size: 16px; font-weight: 600; }
.chat-status { font-size: 12px; color: var(--success); background: var(--success-light); padding: 2px 10px; border-radius: 10px; }
.chat-messages { flex: 1; padding: 24px; overflow-y: auto; display: flex; flex-direction: column; gap: 16px; }
.message { display: flex; gap: 12px; max-width: 75%; }
.message.user { align-self: flex-end; flex-direction: row-reverse; }
.message-avatar { width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.message.bot .message-avatar { background: linear-gradient(135deg, var(--primary), var(--secondary)); }
.message.user .message-avatar { background: #e8f5e9; }
.message-bubble { padding: 12px 16px; border-radius: 16px; font-size: 14px; line-height: 1.7; }
.message.bot .message-bubble { background: #f1f3f5; border-top-left-radius: 4px; text-align: left; padding: 12px 16px 12px 20px; }
.message.bot .message-bubble h1 { font-size: 17px; font-weight: 600; margin: 8px 0 4px; }
.message.bot .message-bubble h2 { font-size: 16px; font-weight: 600; margin: 8px 0 4px; }
.message.bot .message-bubble h3 { font-size: 15px; font-weight: 600; margin: 6px 0 3px; }
.message.bot .message-bubble ol,
.message.bot .message-bubble ul { padding-left: 14px; margin: 6px 0; }
.message.bot .message-bubble li { margin: 3px 0; }
.message.bot .message-bubble li ol,
.message.bot .message-bubble li ul { padding-left: 26px; margin: 4px 0; }
.message.bot .message-bubble code { background: #e2e4e8; padding: 1px 5px; border-radius: 4px; font-size: 13px; }
.message.bot .message-bubble pre { background: #e8eaed; padding: 10px; border-radius: 8px; overflow-x: auto; margin: 8px 0; font-size: 12px; }
.message.bot .message-bubble pre code { background: none; padding: 0; }
.message.bot .message-bubble p { margin: 4px 0; }
.message.bot .message-bubble blockquote { border-left: 3px solid #ccc; padding-left: 10px; color: #555; margin: 6px 0; }
.message.user .message-bubble { background: var(--primary); color: #fff; border-top-right-radius: 4px; }
.chat-input-area { padding: 16px 24px; border-top: 1px solid var(--border); display: flex; gap: 12px; align-items: center; }
.chat-input { flex: 1; padding: 12px 16px; border: 1.5px solid var(--border); border-radius: 24px; font-size: 14px; outline: none; transition: var(--transition); }
.chat-input:focus { border-color: var(--primary); }
.chat-send { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--secondary)); color: #fff; border: none; cursor: pointer; font-size: 18px; display: flex; align-items: center; justify-content: center; }
.chat-send:disabled { opacity: 0.5; cursor: not-allowed; }

/* 文件上传按钮 */
.chat-upload-btn {
    width: 40px; height: 40px; border-radius: 50%;
    background: #f1f3f5; color: var(--text-secondary);
    border: none; cursor: pointer; font-size: 18px;
    display: flex; align-items: center; justify-content: center;
    transition: var(--transition); flex-shrink: 0;
}
.chat-upload-btn:hover { background: var(--primary-light); color: var(--primary); }
.chat-upload-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* 拖拽遮罩 */
.drag-overlay {
    position: absolute; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(102, 126, 234, 0.08);
    border: 3px dashed var(--primary);
    border-radius: var(--radius);
    display: none; align-items: center; justify-content: center;
    z-index: 10; pointer-events: none;
}
.drag-overlay.active { display: flex; }
.drag-overlay-content { text-align: center; color: var(--primary); }
.drag-icon { font-size: 48px; margin-bottom: 12px; }
.drag-text { font-size: 16px; font-weight: 600; }

/* 让 chat-messages 成为定位容器 */
.chat-messages { position: relative; }

/* 上传状态 */
.upload-status { display: flex; align-items: center; gap: 10px; }
.upload-spinner {
    width: 18px; height: 18px;
    border: 2px solid #e2e8f0;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.upload-status-text { font-size: 14px; color: var(--text-secondary); }

.upload-success {
    padding: 4px 0;
    line-height: 1.6;
}
.upload-success strong { color: var(--success); }

.file-icon { margin-right: 4px; }

/* Chat Sidebar - Features */
.chat-sidebar { width: 280px; border-left: 1px solid var(--border); padding: 20px; overflow-y: auto; }
.sidebar-section-title { font-size: 13px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 12px; }
.feature-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm); margin-bottom: 6px; transition: var(--transition); }
.feature-item:hover { background: var(--primary-light); }
.feature-item.locked { opacity: 0.45; }
.feature-icon { font-size: 18px; }
.feature-name { font-size: 13px; font-weight: 500; flex: 1; }
.feature-badge { font-size: 10px; padding: 2px 8px; border-radius: 10px; font-weight: 600; }
.feature-badge.available { background: #e8f5e9; color: #2e7d32; }
.feature-badge.locked { background: #fee2e2; color: #dc2626; }

/* Login Page */
.login-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.login-card { background: #fff; border-radius: 20px; padding: 40px 36px; box-shadow: 0 20px 60px rgba(0,0,0,0.2); width: 100%; max-width: 420px; }
.login-header { text-align: center; margin-bottom: 32px; }
.login-logo { font-size: 48px; margin: 0 auto 6px; width: 88px; height: 88px; display: flex; align-items: center; justify-content: center; border-radius: 20px; overflow: hidden; }
.login-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.login-header h1 { font-size: 24px; font-weight: 700; } .login-subtitle { font-size: 14px; color: var(--text-secondary); margin-top: 6px; }
.login-form .form-group { margin-bottom: 20px; }
.login-form label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.login-form input { width: 100%; padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: 14px; outline: none; transition: var(--transition); background: #fafbfc; }
.login-form input:focus { border-color: var(--primary); background: #fff; box-shadow: 0 0 0 3px rgba(102,126,234,0.1); }
.login-form .btn { margin-top: 8px; }
.btn-block { width: 100%; padding: 12px; font-size: 15px; }
.btn-primary { background: linear-gradient(135deg, var(--primary), var(--secondary)); color: #fff; border: none; border-radius: var(--radius-sm); font-weight: 600; cursor: pointer; transition: var(--transition); }
.btn-primary:hover { opacity: 0.9; }
.login-footer { text-align: center; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--border); }
.login-footer p { font-size: 13px; color: var(--text-muted); }
.login-error { background: var(--danger-light); color: var(--danger); padding: 10px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 13px; text-align: center; display: none; }
.demo-accounts { margin-top: 16px; }
.demo-title { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; }
.demo-list { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.demo-tag { padding: 4px 12px; border-radius: 14px; font-size: 11px; font-weight: 500; background: var(--primary-light); color: var(--primary-dark); }

/* Data Table */
.data-table { width: 100%; border-collapse: collapse; background: var(--bg-card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.data-table thead { background: #f8f9fb; }
.data-table th { padding: 14px 20px; text-align: left; font-size: 12px; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.5px; border-bottom: 1px solid var(--border); }
.data-table td { padding: 14px 20px; font-size: 14px; border-bottom: 1px solid #f1f3f6; }
.data-table tbody tr:hover { background: #f8f9fb; }
.type-tag { display: inline-block; padding: 2px 10px; border-radius: 12px; font-size: 12px; font-weight: 500; }
.type-xiaohongshu { background: #ebf4ff; color: #3182ce; }
.type-gongzhonghao { background: #f0fff4; color: #2e7d32; }
.type-sel-school { background: #fffbeb; color: #c05621; }
.type-document { background: #f3e8ff; color: #7c3aed; }

/* Change Password */
.password-card { background: var(--bg-card); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); max-width: 480px; margin: 0 auto; }
.password-card h2 { font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.password-card .hint { font-size: 14px; color: var(--text-secondary); margin-bottom: 24px; }

/* Empty State */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state .icon { font-size: 48px; margin-bottom: 16px; }
.empty-state p { font-size: 14px; }

/* Disabled state for expired accounts */
.disabled-overlay { position: relative; }
.disabled-overlay::after { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(255,255,255,0.7); display: flex; align-items: center; justify-content: center; border-radius: var(--radius); z-index: 10; }

/* Feature List Card */
.feature-list-card { background: var(--bg-card); border-radius: var(--radius); padding: 20px 24px; box-shadow: var(--shadow); margin-bottom: 24px; }
.feature-item { display: flex; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border); }
.feature-item:last-child { border-bottom: none; }
.feature-item:first-child { padding-top: 0; }
.feature-icon { font-size: 20px; margin-right: 12px; width: 28px; text-align: center; }
.feature-name { flex: 1; font-size: 14px; font-weight: 500; color: var(--text-primary); }
.feature-status { font-size: 12px; padding: 4px 12px; border-radius: 20px; font-weight: 500; }
.feature-available { background: var(--success-light); color: var(--success); }
.feature-unavailable { background: var(--danger-light); color: var(--danger); }

/* Upgrade Section */
.upgrade-section { text-align: center; padding-top: 16px; margin-top: 8px; border-top: 1px dashed var(--border); }
.upgrade-btn { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; border: none; padding: 12px 32px; border-radius: 24px; font-size: 15px; font-weight: 600; cursor: pointer; transition: var(--transition); box-shadow: 0 4px 15px rgba(102,126,234,0.3); }
.upgrade-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(102,126,234,0.4); }

/* Upgrade Modal */
.modal-overlay { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); z-index: 9999; align-items: center; justify-content: center; }
.modal-overlay.active { display: flex; }
.modal-box { background: white; border-radius: 16px; padding: 32px; max-width: 480px; width: 90%; box-shadow: 0 20px 60px rgba(0,0,0,0.2); animation: modalIn 0.3s ease; }
@keyframes modalIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.modal-box h3 { font-size: 20px; margin-bottom: 8px; text-align: center; }
.modal-box .subtitle { font-size: 13px; color: var(--text-secondary); text-align: center; margin-bottom: 20px; }
.plan-options { display: flex; flex-direction: column; gap: 12px; margin-bottom: 20px; }
.plan-option { border: 2px solid var(--border); border-radius: 12px; padding: 16px; cursor: pointer; transition: var(--transition); display: flex; justify-content: space-between; align-items: center; }
.plan-option:hover { border-color: var(--primary); background: var(--primary-light); }
.plan-option .plan-name { font-weight: 600; font-size: 15px; }
.plan-option .plan-desc { font-size: 12px; color: var(--text-secondary); margin-top: 4px; }
.plan-option .plan-price { font-size: 18px; font-weight: 700; color: var(--primary); }
.modal-close { display: block; width: 100%; padding: 10px; border: 1px solid var(--border); border-radius: 8px; background: white; cursor: pointer; font-size: 14px; color: var(--text-secondary); }
.modal-close:hover { background: #f5f5f5; }

/* Plans Grid */
.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.plan-card {
    background: var(--bg-card); border-radius: var(--radius); padding: 28px;
    box-shadow: var(--shadow); text-align: center; position: relative;
    transition: var(--transition); border: 2px solid transparent;
}
.plan-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.plan-card-featured { border-color: var(--primary); }
.plan-badge {
    position: absolute; top: -10px; right: 20px;
    background: linear-gradient(135deg, #667eea, #764ba2); color: white;
    padding: 4px 14px; border-radius: 12px; font-size: 12px; font-weight: 600;
}
.plan-icon { font-size: 40px; margin-bottom: 12px; }
.plan-title { font-size: 20px; font-weight: 700; margin-bottom: 12px; }
.plan-price { margin-bottom: 20px; }
.price-amount { font-size: 36px; font-weight: 800; color: var(--primary); }
.price-period { font-size: 14px; color: var(--text-secondary); }
.plan-features { list-style: none; text-align: left; margin-bottom: 24px; }
.plan-features li { padding: 6px 0; font-size: 14px; border-bottom: 1px solid #f0f0f0; }
.plan-features li:last-child { border-bottom: none; }
.plan-btn {
    display: inline-block; width: 100%; padding: 12px;
    background: linear-gradient(135deg, #667eea, #764ba2); color: white;
    border-radius: 24px; text-decoration: none; font-weight: 600;
    transition: var(--transition);
}
.plan-btn:hover { opacity: 0.9; transform: translateY(-1px); }

/* ===== Responsive Mobile ===== */
@media (max-width: 768px) {
    /* Sidebar */
    .sidebar { transform: translateX(-100%); transition: transform 0.3s ease; overflow-y: auto; -webkit-overflow-scrolling: touch; }
    .sidebar.open { transform: translateX(0); z-index: 200; }
    .sidebar-header { padding-top: 60px; }
    .sidebar-overlay { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); z-index: 99; }
    .sidebar-overlay.show { display: block; }
    .main-content { margin-left: 0; padding: 16px; padding-top: 56px; }
    .hamburger { display: flex; position: fixed; top: 12px; left: 12px; z-index: 101; width: 36px; height: 36px; border-radius: 8px; background: linear-gradient(135deg, var(--primary), var(--secondary)); color: #fff; align-items: center; justify-content: center; font-size: 20px; cursor: pointer; border: none; box-shadow: var(--shadow); }
    .hamburger { display: flex; }
    
    /* Stats */
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .stat-card { padding: 14px; gap: 10px; }
    .stat-value { font-size: 22px; }
    .stat-icon { width: 36px; height: 36px; font-size: 18px; }
    
    /* Actions */
    .actions-grid { grid-template-columns: 1fr; gap: 12px; }
    .action-card { padding: 16px; }
    .action-icon { font-size: 28px; }
    
    /* Banner */
    .banner { flex-wrap: wrap; padding: 12px 14px; gap: 8px; }
    .banner-action { width: 100%; text-align: center; margin-top: 4px; }
    
    /* Package card */
    .package-card { flex-direction: column; gap: 14px; text-align: center; padding: 18px; }
    
    /* Plans grid */
    .plans-grid { grid-template-columns: 1fr; gap: 16px; }
    
    /* Page header */
    .page-header h1 { font-size: 20px; }
    .page-header p { font-size: 13px; }
    
    /* Chat - 手机端全屏适配 */
    .main-content { padding: 0 !important; padding-top: 56px !important; }
    .chat-container { height: calc(100vh - 56px); border-radius: 0; width: 100%; margin: 0; }
    .chat-sidebar { display: none; }
    .chat-header { padding: 10px 12px; }
    .chat-header h2 { font-size: 14px; }
    .chat-messages { padding: 12px 10px; gap: 12px; }
    .chat-input-area { padding: 10px 12px; }
    .chat-input { padding: 10px 14px; font-size: 14px; }
    .message { max-width: 88%; gap: 8px; }
    .message-avatar { width: 30px; height: 30px; font-size: 15px; border-radius: 8px; }
    .message-bubble { padding: 10px 14px; font-size: 14px; line-height: 1.6; border-radius: 14px; }
    .message.bot .message-bubble { padding: 10px 14px 10px 16px; }
    /* 建议追问手机端：横向排列，自动换行 */
    .suggestions-container { max-width: 100% !important; box-sizing: border-box; padding: 8px 0 4px !important; margin-top: 8px !important; }
    .suggestions-container > div:last-child { flex-direction: column !important; gap: 6px !important; }
    .suggestions-container button { width: 100% !important; text-align: left !important; font-size: 13px !important; padding: 8px 12px !important; min-height: auto !important; }
    
    /* Table → Card */
    .data-table { display: block; box-shadow: none; }
    .data-table thead { display: none; }
    .data-table tbody { display: block; }
    .data-table tr { display: block; background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; }
    .data-table td { display: flex; padding: 6px 0; border: none; font-size: 14px; }
    .data-table td::before { content: attr(data-label); font-weight: 600; color: var(--text-secondary); min-width: 80px; margin-right: 12px; font-size: 12px; }
    
    /* Login */
    .login-card { padding: 28px 20px; margin: 12px; }
    .login-logo { font-size: 36px; }
    .login-header h1 { font-size: 20px; }
    
    /* Password card */
    .password-card { padding: 20px; margin: 0 12px; }
    
    /* Modal */
    .modal-box { padding: 24px; width: 95%; margin: 0 8px; }
    .plan-options { gap: 8px; }
    .plan-option { padding: 12px; flex-direction: column; align-items: flex-start; gap: 8px; }
    
    /* Feature list */
    .feature-list-card { padding: 16px; }
    .feature-item { padding: 10px 0; }
    
    /* Forms */
    .login-form input, .form-row input, .form-row select { width: 100%; font-size: 14px; }
}

@media (max-width: 380px) {
    .stats-grid { grid-template-columns: 1fr; }
    .main-content { padding: 12px; padding-top: 56px; }
}

/* Hamburger visible on mobile, hidden on desktop via media query above */

/* ============ 文案生成 & 图片设计增强 ============ */

/* 消息操作按钮栏 */
.msg-actions { display:flex; gap:6px; padding:8px 0 2px; margin-top:10px; border-top:1px solid rgba(0,0,0,0.06); flex-wrap:wrap; }
.action-btn { background:#f0f7ff; border:1px solid #d0e3ff; border-radius:6px; padding:5px 12px; font-size:12px; color:#2563eb; cursor:pointer; transition:all 0.2s; display:inline-flex; align-items:center; gap:4px; }
.action-btn:hover { background:#e0efff; transform:translateY(-1px); box-shadow:0 2px 6px rgba(37,99,235,0.15); }
.action-btn.success { background:#f0fdf4; border-color:#86efac; color:#16a34a; }

/* 图片灯箱 */
.image-lightbox { position:fixed; top:0; left:0; right:0; bottom:0; background:rgba(0,0,0,0.88); z-index:99999; display:flex; align-items:center; justify-content:center; opacity:0; transition:opacity 0.3s; pointer-events:none; flex-direction:column; }
.image-lightbox.active { opacity:1; pointer-events:auto; }
.lightbox-close { position:absolute; top:16px; right:20px; color:white; font-size:24px; cursor:pointer; width:40px; height:40px; display:flex; align-items:center; justify-content:center; border-radius:50%; background:rgba(255,255,255,0.12); transition:background 0.2s; }
.lightbox-close:hover { background:rgba(255,255,255,0.25); }
.lightbox-img { max-width:90vw; max-height:75vh; border-radius:12px; box-shadow:0 8px 40px rgba(0,0,0,0.5); }
.lightbox-actions { display:flex; gap:10px; margin-top:16px; }
.lightbox-actions button { background:rgba(255,255,255,0.12); color:white; border:1px solid rgba(255,255,255,0.25); border-radius:8px; padding:8px 20px; font-size:13px; cursor:pointer; transition:all 0.2s; }
.lightbox-actions button:hover { background:rgba(255,255,255,0.22); }

/* AI生成图片块 */
.ai-image-block { margin:10px 0; text-align:center; }
.ai-image-block img { max-width:100%; border-radius:10px; cursor:pointer; transition:transform 0.2s; box-shadow:0 2px 12px rgba(0,0,0,0.1); }
.ai-image-block img:hover { transform:scale(1.02); }
.ai-image-actions { margin-top:8px; }
.ai-image-actions button { background:#f0f7ff; border:1px solid #d0e3ff; border-radius:6px; padding:5px 14px; font-size:12px; color:#2563eb; cursor:pointer; }

/* Markdown表格美化 */
.message-bubble table { border-collapse:collapse; width:100%; margin:10px 0; font-size:13px; }
.message-bubble th, .message-bubble td { border:1px solid #e2e8f0; padding:8px 12px; text-align:left; }
.message-bubble th { background:#f7fafc; font-weight:600; color:#4a5568; }
.message-bubble tr:hover td { background:#f7fafc; }

/* 代码块增强 */
.message-bubble pre { background:#1e1e2e; color:#cdd6f4; padding:14px; border-radius:10px; overflow-x:auto; font-size:12px; line-height:1.6; margin:10px 0; position:relative; }
.message-bubble code { font-family:'JetBrains Mono','Fira Code',Consolas,monospace; font-size:13px; }
.message-bubble p > code { background:#e8eaed; padding:2px 6px; border-radius:4px; color:#d63384; font-size:12px; }

/* 内容类型标签 */
.content-type-badge { display:inline-flex; align-items:center; gap:4px; padding:3px 10px; border-radius:12px; font-size:11px; font-weight:600; margin-bottom:8px; }
.badge-copywriting { background:#fef3c7; color:#92400e; }
.badge-image { background:#ede9fe; color:#6d28d9; }
.badge-school { background:#dbeafe; color:#1e40af; }

/* 引用块美化 */
.message-bubble blockquote { border-left:3px solid var(--primary); padding:8px 12px; margin:8px 0; background:rgba(102,126,234,0.04); border-radius:0 6px 6px 0; color:#555; font-style:italic; }
