/* ============================================
   灵创AI - 全局样式
   复刻深色主题设计
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0f0515;
    --bg-secondary: #1a0a22;
    --bg-card: rgba(30, 10, 40, 0.6);
    --bg-card-hover: rgba(40, 15, 55, 0.8);
    --text-primary: #ffffff;
    --text-secondary: #b0a0c0;
    --text-muted: #706080;
    --accent-primary: #ff0080;
    --accent-secondary: #ff40a0;
    --accent-gradient: linear-gradient(135deg, #ff0080 0%, #ff40a0 100%);
    --border-color: rgba(255, 0, 128, 0.2);
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
}

/* 网格背景 */
body {
    background-color: var(--bg-primary);
    background-image: 
        linear-gradient(rgba(255, 0, 128, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 0, 128, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at center, rgba(255, 0, 128, 0.1) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
}

.navbar-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: var(--accent-gradient);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 36px;
    list-style: none;
}

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--text-primary);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 22px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.3s;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent-primary);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-outline:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-lg {
    padding: 14px 32px;
    font-size: 16px;
    border-radius: var(--radius-lg);
}

/* Hero区域 */
.hero {
    padding: 140px 24px 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 28px;
}

.hero-badge .dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.hero h1 {
    font-size: 64px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero h1 span {
    display: block;
    font-size: 48px;
    background: var(--text-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 60px;
}

/* 数据统计 */
.stats {
    display: flex;
    justify-content: center;
    gap: 80px;
    margin-bottom: 80px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 42px;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
}

/* 功能标签切换 */
.feature-tabs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.feature-tab {
    padding: 12px 28px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.feature-tab:hover {
    border-color: var(--accent-primary);
    color: var(--text-primary);
}

.feature-tab.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
}

/* 预览区域 */
.preview-section {
    max-width: 900px;
    margin: 0 auto 100px;
}

.preview-container {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px;
    border-bottom: 1px solid var(--border-color);
}

.preview-title {
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.preview-title .live-dot {
    width: 10px;
    height: 10px;
    background: var(--error);
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.preview-params {
    display: flex;
    gap: 24px;
    font-size: 13px;
    color: var(--text-muted);
}

.preview-params span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.preview-params strong {
    color: var(--text-secondary);
    font-weight: 600;
}

.preview-content {
    position: relative;
    aspect-ratio: 16/9;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.preview-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
}

.progress-bar {
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 2px;
    width: 75%;
    animation: progress 3s ease-in-out infinite;
}

@keyframes progress {
    0%, 100% { width: 30%; }
    50% { width: 85%; }
}

.preview-status {
    font-size: 14px;
    color: var(--text-secondary);
}

/* 通用区块 */
.section {
    padding: 80px 24px;
    max-width: 1280px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-tag {
    display: inline-block;
    padding: 6px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    font-size: 13px;
    color: var(--accent-primary);
    font-weight: 600;
    margin-bottom: 16px;
}

.section-title {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 17px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* 能力卡片 */
.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.capability-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px 28px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.capability-card:hover {
    transform: translateY(-6px);
    border-color: var(--accent-primary);
    box-shadow: 0 20px 40px rgba(99, 102, 241, 0.15);
}

.capability-card.recommended::before {
    content: '推荐';
    position: absolute;
    top: 16px;
    right: 16px;
    padding: 4px 12px;
    background: var(--accent-gradient);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

.capability-icon {
    width: 56px;
    height: 56px;
    background: var(--accent-gradient);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin-bottom: 20px;
}

.capability-card h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 10px;
}

.capability-card p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.7;
}

.capability-card .btn {
    width: 100%;
}

/* 工作流程 */
.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    position: relative;
}

.step-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px 32px;
    text-align: center;
    position: relative;
}

.step-number {
    font-size: 64px;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 16px;
}

.step-card h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.step-card p {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* 定价方案 */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    max-width: 1000px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px 32px;
    transition: all 0.3s;
    position: relative;
}

.pricing-card:hover {
    transform: translateY(-6px);
}

.pricing-card.featured {
    border-color: var(--accent-primary);
    background: linear-gradient(180deg, rgba(99, 102, 241, 0.1) 0%, var(--bg-card) 100%);
    transform: scale(1.05);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-6px);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 20px;
    background: var(--accent-gradient);
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    color: white;
}

.pricing-name {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.pricing-desc {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.pricing-price {
    margin-bottom: 28px;
}

.pricing-price .amount {
    font-size: 42px;
    font-weight: 800;
}

.pricing-price .period {
    font-size: 16px;
    color: var(--text-muted);
}

.pricing-features {
    list-style: none;
    margin-bottom: 32px;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    font-size: 14px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 700;
    font-size: 16px;
}

.pricing-card .btn {
    width: 100%;
}

.pricing-note {
    text-align: center;
    margin-top: 32px;
    font-size: 14px;
    color: var(--text-muted);
}

/* CTA区域 */
.cta-section {
    text-align: center;
    padding: 100px 24px;
    position: relative;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.cta-section h2 {
    font-size: 48px;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
}

.cta-section h2 span {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.cta-section p {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

/* 作品展示 */
.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.gallery-filter {
    padding: 10px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.gallery-filter:hover,
.gallery-filter.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.gallery-item {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    aspect-ratio: 3/4;
    cursor: pointer;
    transition: transform 0.3s;
}

.gallery-item:hover {
    transform: translateY(-4px);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-item-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    opacity: 0;
    transition: opacity 0.3s;
}

.gallery-item:hover .gallery-item-overlay {
    opacity: 1;
}

.gallery-item-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 8px;
}

.gallery-item-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
}

.gallery-item-tags {
    display: flex;
    gap: 6px;
}

.gallery-tag {
    padding: 3px 10px;
    background: rgba(255,255,255,0.15);
    border-radius: 100px;
    font-size: 11px;
}

.gallery-tag.video {
    background: var(--accent-primary);
}

.gallery-load-more {
    text-align: center;
    margin-top: 48px;
}

/* 页脚 */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 60px 24px 30px;
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand .logo {
    margin-bottom: 16px;
}

.footer-brand p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s;
}

.footer-social a:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.footer-column h4 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 20px;
}

.footer-column ul {
    list-style: none;
}

.footer-column li {
    margin-bottom: 12px;
}

.footer-column a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* 响应式 */
@media (max-width: 1024px) {
    .capabilities-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 40px;
    }
    
    .hero h1 span {
        font-size: 32px;
    }
    
    .stats {
        gap: 40px;
        flex-wrap: wrap;
    }
    
    .stat-number {
        font-size: 32px;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .capabilities-grid,
    .steps,
    .pricing-grid {
        grid-template-columns: 1fr;
    }
    
    .pricing-card.featured {
        transform: none;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .nav-menu {
        display: none;
    }
    
    .cta-section h2 {
        font-size: 32px;
    }
}

/* 生成器页面样式 */
.generate-page {
    padding-top: 88px;
    min-height: 100vh;
}

.generate-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px;
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 24px;
}

.generate-sidebar {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    height: fit-content;
    position: sticky;
    top: 92px;
}

.sidebar-section {
    margin-bottom: 28px;
}

.sidebar-section:last-child {
    margin-bottom: 0;
}

.sidebar-title {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mode-tabs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.mode-tab {
    padding: 14px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.mode-tab:hover {
    border-color: var(--accent-primary);
}

.mode-tab.active {
    background: var(--accent-gradient);
    border-color: transparent;
}

.mode-tab-icon {
    font-size: 24px;
    margin-bottom: 6px;
}

.mode-tab-label {
    font-size: 13px;
    font-weight: 500;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
    font-family: inherit;
}

.upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.upload-area:hover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
}

.upload-icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.upload-text {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.upload-hint {
    font-size: 12px;
    color: var(--text-muted);
}

.params-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.param-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.param-item:hover,
.param-item.active {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.param-item-label {
    font-size: 13px;
    font-weight: 500;
}

.param-item-value {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

.switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
}

.switch-label {
    font-size: 14px;
    color: var(--text-secondary);
}

.switch {
    position: relative;
    width: 48px;
    height: 26px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    transition: .3s;
    border-radius: 26px;
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: var(--text-muted);
    transition: .3s;
    border-radius: 50%;
}

.switch input:checked + .switch-slider {
    background: var(--accent-gradient);
    border-color: transparent;
}

.switch input:checked + .switch-slider:before {
    transform: translateX(22px);
    background-color: white;
}

.generate-btn {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    border-radius: var(--radius-md);
}

.generate-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.preview-area {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.preview-placeholder {
    text-align: center;
    color: var(--text-muted);
}

.preview-placeholder-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.preview-placeholder-text {
    font-size: 16px;
}

.result-image {
    max-width: 100%;
    max-height: 600px;
    object-fit: contain;
}

.result-actions {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
}

.history-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.history-title {
    font-size: 16px;
    font-weight: 600;
}

.history-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.history-item {
    aspect-ratio: 1;
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.history-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.history-item-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.history-item:hover .history-item-overlay {
    opacity: 1;
}

/* 后台管理样式 */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 260px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
}

.admin-logo {
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-logo .logo-icon {
    width: 40px;
    height: 40px;
}

.admin-logo-text {
    font-size: 18px;
    font-weight: 700;
}

.admin-menu {
    padding: 16px 12px;
}

.admin-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 4px;
    transition: all 0.3s;
}

.admin-menu-item:hover {
    background: var(--bg-card);
    color: var(--text-primary);
}

.admin-menu-item.active {
    background: var(--accent-gradient);
    color: white;
}

.admin-menu-icon {
    font-size: 20px;
}

.admin-main {
    flex: 1;
    margin-left: 260px;
}

.admin-header {
    height: 68px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.admin-header-title {
    font-size: 20px;
    font-weight: 700;
}

.admin-header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.admin-content {
    padding: 32px;
}

/* 统计卡片 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.stat-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.stat-card-title {
    font-size: 14px;
    color: var(--text-muted);
}

.stat-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.stat-card-icon.purple { background: rgba(139, 92, 246, 0.2); color: #8b5cf6; }
.stat-card-icon.blue { background: rgba(59, 130, 246, 0.2); color: #3b82f6; }
.stat-card-icon.green { background: rgba(16, 185, 129, 0.2); color: #10b981; }
.stat-card-icon.orange { background: rgba(245, 158, 11, 0.2); color: #f59e0b; }

.stat-card-value {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
}

.stat-card-change {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.stat-card-change.up { color: var(--success); }
.stat-card-change.down { color: var(--error); }

/* 数据表格 */
.data-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
}

.data-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.data-card-title {
    font-size: 16px;
    font-weight: 600;
}

.data-card-actions {
    display: flex;
    gap: 12px;
}

.search-input {
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    width: 240px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    padding: 14px 24px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.data-table td {
    padding: 16px 24px;
    font-size: 14px;
    border-bottom: 1px solid var(--border-color);
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover {
    background: var(--bg-secondary);
}

.user-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

.user-info-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.user-info-email {
    font-size: 12px;
    color: var(--text-muted);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.active {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.status-badge.inactive {
    background: rgba(107, 114, 128, 0.15);
    color: var(--text-muted);
}

.status-badge.pending {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.status-badge.danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

.action-btns {
    display: flex;
    gap: 8px;
}

.action-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.3s;
}

.action-btn:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.action-btn.delete:hover {
    border-color: var(--error);
    color: var(--error);
}

/* 分页 */
.pagination {
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--border-color);
}

.pagination-info {
    font-size: 14px;
    color: var(--text-muted);
}

.pagination-btns {
    display: flex;
    gap: 8px;
}

.pagination-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.3s;
}

.pagination-btn:hover,
.pagination-btn.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
}

/* 登录页面 */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    position: relative;
}

.auth-page::before {
    content: '';
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 48px 40px;
    position: relative;
    z-index: 1;
}

.auth-header {
    text-align: center;
    margin-bottom: 36px;
}

.auth-logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.auth-logo .logo-icon {
    width: 48px;
    height: 48px;
    font-size: 24px;
}

.auth-logo-text {
    font-size: 24px;
    font-weight: 700;
}

.auth-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.auth-subtitle {
    font-size: 14px;
    color: var(--text-muted);
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form .form-input {
    padding: 14px 16px;
}

.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
}

.forgot-password {
    font-size: 14px;
    color: var(--accent-primary);
    text-decoration: none;
}

.auth-btn {
    width: 100%;
    padding: 14px;
    font-size: 16px;
    margin-bottom: 24px;
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.auth-divider span {
    font-size: 13px;
    color: var(--text-muted);
}

.social-login {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}

.social-btn {
    padding: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.3s;
    font-size: 20px;
}

.social-btn:hover {
    border-color: var(--accent-primary);
}

.auth-footer {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
}

/* 作品详情弹窗 */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
}

.modal-image {
    flex: 1;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-image img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.modal-info {
    width: 320px;
    padding: 24px;
    border-left: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.modal-author {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.modal-author-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.modal-author-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.modal-author-time {
    font-size: 12px;
    color: var(--text-muted);
}

.modal-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
}

.modal-prompt {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.modal-params {
    margin-bottom: 20px;
}

.modal-param-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 13px;
    border-bottom: 1px solid var(--border-color);
}

.modal-param-label {
    color: var(--text-muted);
}

.modal-param-value {
    font-weight: 500;
}

.modal-actions {
    margin-top: auto;
    display: flex;
    gap: 10px;
}

.modal-actions .btn {
    flex: 1;
}

/* 提示框 */
.toast {
    position: fixed;
    top: 100px;
    right: 24px;
    padding: 16px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    z-index: 3000;
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast.success {
    border-left: 4px solid var(--success);
}

.toast.error {
    border-left: 4px solid var(--error);
}

.toast-icon {
    font-size: 20px;
}

.toast-message {
    font-size: 14px;
}

/* 客服气泡按钮 */
.chat-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
}

.chat-bubble-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
    transition: all 0.3s ease;
    position: relative;
    font-size: 26px;
}

.chat-bubble-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.5);
}

.chat-bubble-btn .notification-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 18px;
    height: 18px;
    background: var(--danger);
    border-radius: 50%;
    border: 2px solid var(--bg-primary);
    font-size: 10px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.chat-bubble-btn .pulse-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--accent-primary);
    opacity: 0.4;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.4;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* 客服弹窗 */
.chat-popup {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 360px;
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--border-color);
    overflow: hidden;
    display: none;
    animation: slideUp 0.3s ease;
}

.chat-popup.active {
    display: block;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-popup-header {
    background: var(--accent-gradient);
    padding: 20px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chat-popup-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-popup-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.chat-popup-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 2px;
}

.chat-popup-subtitle {
    font-size: 12px;
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 4px;
}

.chat-popup-subtitle .online-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    display: inline-block;
}

.chat-popup-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    transition: background 0.2s;
}

.chat-popup-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.chat-popup-body {
    padding: 20px;
    height: 320px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.chat-message {
    display: flex;
    gap: 10px;
    max-width: 85%;
}

.chat-message.bot {
    align-self: flex-start;
}

.chat-message.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.chat-message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.chat-message-content {
    background: var(--bg-tertiary);
    padding: 10px 14px;
    border-radius: 16px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text-primary);
}

.chat-message.bot .chat-message-content {
    border-bottom-left-radius: 4px;
}

.chat-message.user .chat-message-content {
    background: var(--accent-primary);
    color: white;
    border-bottom-right-radius: 4px;
}

.chat-quick-replies {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0 20px 16px;
}

.chat-quick-reply {
    padding: 8px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 13px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
}

.chat-quick-reply:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.chat-popup-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
    align-items: center;
}

.chat-input {
    flex: 1;
    padding: 10px 16px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.chat-input:focus {
    border-color: var(--accent-primary);
}

.chat-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    transition: transform 0.2s;
    border: none;
}

.chat-send-btn:hover {
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .chat-popup {
        width: calc(100vw - 48px);
        right: -12px;
    }
    
    .chat-bubble-btn {
        width: 52px;
        height: 52px;
        font-size: 22px;
    }
}

/* 导航栏用户区域 */
.nav-user-area {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-credits {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--text-secondary);
}

.nav-credits-value {
    color: var(--accent-primary);
    font-weight: 600;
}

.nav-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    position: relative;
}

.nav-user-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    min-width: 180px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: none;
    z-index: 1000;
}

.nav-user-menu.active {
    display: block;
}

.nav-user-menu-item {
    padding: 12px 16px;
    font-size: 14px;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background 0.2s;
}

.nav-user-menu-item:hover {
    background: var(--bg-tertiary);
}

.nav-user-menu-item.danger {
    color: var(--danger);
}

.nav-user-menu-divider {
    height: 1px;
    background: var(--border-color);
    margin: 4px 0;
}
