/* 重置和基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* 浅色主题变量 */
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #10b981;
    --accent-color: #8b5cf6;
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-color: #ffffff;
    --bg-secondary: #f9fafb;
    --bg-tertiary: #f3f4f6;
    --border-color: #e5e7eb;
    --card-bg: #ffffff;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
    --radius: 12px;
    --radius-lg: 16px;
    --transition: all 0.3s ease;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'Monaco', 'Menlo', 'Consolas', 'Courier New', monospace;
}

.dark-theme {
    /* 深色主题变量 */
    --primary-color: #818cf8;
    --primary-dark: #6366f1;
    --secondary-color: #34d399;
    --accent-color: #a78bfa;
    --text-color: #f9fafb;
    --text-light: #d1d5db;
    --bg-color: #111827;
    --bg-secondary: #1f2937;
    --bg-tertiary: #374151;
    --border-color: #4b5563;
    --card-bg: #1f2937;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 40px -10px rgba(0, 0, 0, 0.4);
}

body {
    font-family: var(--font-sans);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
    transition: var(--transition);
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 */
.navbar {
    background-color: var(--card-bg);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-brand .logo {
    font-size: 2rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.nav-brand h1 {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-light);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.theme-toggle {
    background: none;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1.2rem;
    color: var(--text-light);
}

.theme-toggle:hover {
    background-color: var(--bg-tertiary);
    color: var(--primary-color);
}

/* 英雄区域 */
.hero {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-color) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, var(--primary-color) 0%, transparent 70%);
    opacity: 0.05;
    z-index: 0;
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2.5rem;
    max-width: 500px;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 0.875rem 2rem;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: var(--bg-tertiary);
    color: var(--text-color);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--border-color);
    transform: translateY(-2px);
}

.hero-visual {
    flex: 1;
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-card {
    position: absolute;
    background-color: var(--card-bg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 1.5rem;
    width: 280px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

#floatingCard1 {
    top: 20%;
    left: 10%;
    animation: float 6s ease-in-out infinite;
    z-index: 2;
}

#floatingCard2 {
    bottom: 20%;
    right: 10%;
    animation: float 6s ease-in-out infinite reverse;
    z-index: 1;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.card-icon {
    font-size: 1.5rem;
}

.card-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
}

.card-content {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-light);
    overflow: hidden;
}

.pdf-preview {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pdf-page {
    height: 30px;
    background-color: var(--bg-tertiary);
    border-radius: 4px;
}

.pdf-page:first-child {
    height: 40px;
    background-color: var(--primary-color);
    opacity: 0.7;
}

.conversion-arrow {
    position: absolute;
    font-size: 3rem;
    color: var(--primary-color);
    animation: pulse 2s infinite;
    z-index: 3;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* 转换器区域 */
.converter {
    padding: 5rem 0;
    background-color: var(--bg-secondary);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 3rem;
    font-size: 1.125rem;
}

.converter-options {
    display: flex;
    justify-content: center;
    margin-bottom: 2.5rem;
}

.option-group {
    display: flex;
    background-color: var(--bg-tertiary);
    padding: 0.5rem;
    border-radius: var(--radius);
    gap: 0.5rem;
}

.option-btn {
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    background: none;
    border: none;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.option-btn.active {
    background-color: var(--card-bg);
    color: var(--primary-color);
    box-shadow: var(--shadow);
}

.option-icon {
    font-size: 1.25rem;
}

.conversion-panel {
    display: none;
    background-color: var(--card-bg);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.conversion-panel.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.panel-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.panel-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
}

.panel-actions {
    display: flex;
    gap: 0.75rem;
}

.action-btn {
    padding: 0.5rem 1rem;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    color: var(--text-color);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.action-btn:hover {
    background-color: var(--border-color);
}

.panel-body {
    padding: 2rem;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 2rem;
}

@media (max-width: 1024px) {
    .panel-body {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }
}

.editor-section, .result-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.editor-header, .result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.editor-header h4, .result-header h4 {
    font-size: 1.125rem;
    font-weight: 600;
}

.file-label {
    padding: 0.5rem 1rem;
    background-color: var(--bg-tertiary);
    border-radius: var(--radius);
    color: var(--text-color);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.file-label:hover {
    background-color: var(--border-color);
}

.editor {
    flex: 1;
    min-height: 300px;
    padding: 1rem;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    font-family: var(--font-mono);
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-color);
    resize: vertical;
    transition: var(--transition);
}

.editor:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.editor-footer, .result-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: var(--text-light);
}

.btn-preview {
    padding: 0.5rem 1.5rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-preview:hover {
    background-color: var(--primary-dark);
}

.middle-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}

.conversion-controls {
    background-color: var(--bg-tertiary);
    padding: 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 250px;
}

.conversion-controls h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    text-align: center;
}

.control-group {
    margin-bottom: 1rem;
}

.control-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-light);
}

.control-group select {
    width: 100%;
    padding: 0.5rem;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    color: var(--text-color);
    font-family: var(--font-sans);
}

.btn-convert {
    width: 100%;
    padding: 0.875rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 1rem;
}

.btn-convert:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.arrow-container {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.animated-arrow {
    font-size: 2.5rem;
    color: var(--primary-color);
    animation: slide 2s ease-in-out infinite;
}

@keyframes slide {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(10px); }
}

.pdf-preview-container {
    flex: 1;
    min-height: 300px;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
}

.preview-placeholder {
    text-align: center;
    color: var(--text-light);
}

.placeholder-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.upload-section {
    grid-column: 1 / -1;
}

.upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    padding: 4rem 2rem;
    text-align: center;
    transition: var(--transition);
    background-color: var(--bg-tertiary);
}

.upload-area.drag-over {
    border-color: var(--primary-color);
    background-color: rgba(99, 102, 241, 0.05);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.7;
}

.upload-area h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.upload-area p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.upload-hint {
    font-size: 0.875rem;
    margin-top: 1rem;
    opacity: 0.7;
}

.uploaded-file {
    margin-top: 2rem;
    background-color: var(--card-bg);
    border-radius: var(--radius);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}

.file-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.file-icon {
    font-size: 2rem;
}

.file-details h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.file-details p {
    color: var(--text-light);
    font-size: 0.875rem;
}

.btn-remove {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-light);
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.btn-remove:hover {
    background-color: var(--bg-tertiary);
    color: #ef4444;
}

.file-progress {
    margin-bottom: 1.5rem;
}

.progress-bar {
    height: 8px;
    background-color: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 4px;
    width: 0%;
    transition: width 0.3s ease;
}

.result-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    min-height: 400px;
}

@media (max-width: 768px) {
    .result-content {
        grid-template-columns: 1fr;
    }
}

.result-view, .result-preview {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.html-preview {
    flex: 1;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1rem;
    overflow: auto;
}

/* 功能特色区域 */
.features {
    padding: 5rem 0;
    background-color: var(--bg-color);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background-color: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-light);
    line-height: 1.7;
}

/* 使用指南区域 */
.how-to {
    padding: 5rem 0;
    background-color: var(--bg-secondary);
}

.steps {
    max-width: 800px;
    margin: 3rem auto 0;
}

.step {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    position: relative;
}

.step:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 40px;
    top: 80px;
    bottom: -60px;
    width: 2px;
    background-color: var(--border-color);
    z-index: 0;
}

.step-number {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    z-index: 1;
}

.step-content {
    padding-top: 1rem;
}

.step-content h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.step-content p {
    color: var(--text-light);
    line-height: 1.7;
}

/* FAQ区域 */
.faq {
    padding: 5rem 0;
    background-color: var(--bg-color);
}

.faq-list {
    max-width: 800px;
    margin: 3rem auto 0;
}

.faq-item {
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem 0;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.faq-question h3 {
    font-size: 1.125rem;
    font-weight: 600;
}

.faq-toggle {
    font-size: 1.5rem;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    color: var(--text-light);
    line-height: 1.7;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    margin-top: 1rem;
}

/* 页脚 */
.footer {
    background-color: var(--card-bg);
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand {
    flex: 1;
    min-width: 250px;
}

.footer-brand .logo {
    font-size: 3rem;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 1rem;
}

.footer-brand h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: var(--text-light);
}

.footer-links {
    display: flex;
    gap: 4rem;
    flex-wrap: wrap;
}

.link-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.link-group h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.link-group a {
    color: var(--text-light);
    text-decoration: none;
    transition: var(--transition);
}

.link-group a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-light);
    font-size: 0.875rem;
}

.footer-note {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    opacity: 0.7;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .hero .container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-description {
        font-size: 1.125rem;
    }
    
    .hero-visual {
        margin-top: 3rem;
        height: 300px;
    }
    
    .floating-card {
        width: 220px;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .panel-body {
        padding: 1.5rem;
    }
    
    .features, .how-to, .faq, .converter {
        padding: 3rem 0;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
    }
    
    .footer-links {
        gap: 2rem;
    }
}

/* 在原有CSS后添加以下样式 */

/* 结果容器样式 */
.result-container {
    flex: 1;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    overflow: hidden;
}

.preview-tabs {
    display: flex;
    background-color: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    background: none;
    border: none;
    border-right: 1px solid var(--border-color);
    color: var(--text-light);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn:hover {
    background-color: var(--bg-tertiary);
    color: var(--text-color);
}

.tab-btn.active {
    background-color: var(--card-bg);
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.tab-content {
    flex: 1;
    display: none;
    overflow: auto;
    padding: 1rem;
}

.tab-content.active {
    display: block;
}

.html-preview {
    background-color: white;
    color: #333;
    padding: 1rem;
    border-radius: 4px;
    min-height: 200px;
    overflow: auto;
}

.html-preview h1, .html-preview h2, .html-preview h3, .html-preview h4 {
    margin-top: 1em;
    margin-bottom: 0.5em;
}

.html-preview p {
    margin-bottom: 1em;
    line-height: 1.6;
}

.html-preview ul, .html-preview ol {
    margin-bottom: 1em;
    padding-left: 2em;
}

.html-preview code {
    background-color: #f1f1f1;
    padding: 0.2em 0.4em;
    border-radius: 3px;
    font-family: var(--font-mono);
}

.html-preview pre {
    background-color: #f5f5f5;
    padding: 1em;
    border-radius: 5px;
    overflow: auto;
    margin-bottom: 1em;
}

.html-preview blockquote {
    border-left: 4px solid #ddd;
    padding-left: 1em;
    margin-left: 0;
    color: #666;
    font-style: italic;
}

/* 加载动画 */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(99, 102, 241, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 成功消息 */
.success-message {
    background-color: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-top: 1rem;
    display: none;
}

/* 错误消息 */
.error-message {
    background-color: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-top: 1rem;
    display: none;
}

/* 在原有CSS后添加以下样式 */

/* 自定义通知 */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    transform: translateX(400px);
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    max-width: 350px;
}

.notification.show {
    transform: translateX(0);
}

.notification-content {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: slideIn 0.5s ease;
}

.notification-icon {
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

.notification-text {
    flex: 1;
    font-weight: 500;
}

.notification-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: background 0.3s ease;
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

/* PDF转Markdown全宽结果区域 */
.result-view.full-width {
    grid-column: 1 / -1;
}

/* 结果内容区域调整 */
.result-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    min-height: 400px;
}

/* 上传区域修复 */
#pdfFileLabel {
    cursor: pointer;
    margin: 0 auto;
    display: inline-block;
}

.upload-area {
    position: relative;
    overflow: hidden;
}

/* 进度条动画 */
.progress-fill {
    transition: width 0.3s ease;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 4px;
}

/* 按钮状态 */
.btn-convert:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 加载状态 */
.converting {
    position: relative;
    color: transparent !important;
}

.converting::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式调整 */
@media (max-width: 768px) {
    .notification {
        left: 20px;
        right: 20px;
        max-width: none;
        transform: translateY(-100px);
    }
    
    .notification.show {
        transform: translateY(0);
    }
    
    .notification-content {
        padding: 0.75rem 1rem;
    }
    
    .panel-body {
        padding: 1rem;
        gap: 1rem;
    }
}