/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Noto Sans SC', 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1d1d1f;
    background: linear-gradient(135deg, #f5f5f7 0%, #ffffff 100%);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

/* 应用切换器样式 */
.app-switcher {
    display: flex;
    align-items: center;
    gap: 16px;
}

.app-switch-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    background: rgba(0, 0, 0, 0.05);
    border: 2px solid transparent;
}

.app-switch-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.app-switch-btn.active {
    background: rgba(250, 208, 100, 0.2);
    border-color: #FAD064;
    box-shadow: 0 2px 8px rgba(250, 208, 100, 0.3);
}

.app-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.app-name {
    font-size: 16px;
    font-weight: 600;
    color: #1d1d1f;
    letter-spacing: 0.01em;
}

.nav-icon-text {
    font-size: 14px;
    opacity: 0.8;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.nav-link:hover .nav-icon-text {
    opacity: 1;
    transform: scale(1.1);
}

.nav-logo a {
    font-size: 18px;
    font-weight: 600;
    color: #FAD064;
    text-decoration: none;
    letter-spacing: 0.02em;
}

.nav-logo a:hover {
    color: #e6c25a;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 20px;
}

.nav-link {
    color: #1d1d1f;
    text-decoration: none;
    font-weight: 400;
    font-size: 15px;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    padding: 6px 12px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link:hover {
    color: #FAD064;
    background: rgba(250, 208, 100, 0.1);
}

/* 主页区域 */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(250, 208, 100, 0.9) 0%, rgba(240, 184, 77, 0.9) 50%, rgba(230, 194, 90, 0.9) 100%);
    padding: 80px 24px 60px;
    position: relative;
    overflow: hidden;
}

/* 应用容器样式 */
.app-container {
    display: none;
}

.app-container.active {
    display: block;
}

/* 知味辅食主题样式 */
.tastesprout-theme.hero-section {
    background: linear-gradient(135deg, rgba(250, 208, 100, 0.9) 0%, rgba(240, 184, 77, 0.9) 50%, rgba(230, 194, 90, 0.9) 100%);
}

.tastesprout-theme.documents-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

/* Ctrl+J主题样式 */
.ctrlj-theme.hero-section {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.ctrlj-theme.documents-section {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.ctrlj-title {
    color: #2c3e50 !important;
}

.ctrlj-subtitle {
    color: #34495e !important;
}

.ctrlj-section-title {
    color: #2c3e50 !important;
}

.ctrlj-section-title::after {
    background: linear-gradient(90deg, #34495e, #2c3e50) !important;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
}

.hero-content {
    text-align: center;
    max-width: 900px;
    z-index: 1;
    position: relative;
}

.main-title {
    font-size: 4.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 16px;
    letter-spacing: -0.01em;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

.subtitle {
    font-size: 1.6rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 24px;
    font-weight: 300;
    line-height: 1.4;
    letter-spacing: 0.02em;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* iOS下载按钮 */
.download-section {
    margin-bottom: 40px;
}

.ios-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.95);
    color: #1d1d1f;
    text-decoration: none;
    padding: 16px 32px;
    border-radius: 28px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.1),
        0 8px 32px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.3);
    position: relative;
    overflow: hidden;
}

.ios-download-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.ios-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.15),
        0 16px 48px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 1);
}

.btn-icon {
    font-size: 1.2rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.btn-text {
    font-weight: 600;
    letter-spacing: 0.01em;
}

/* Ctrl+J 下载按钮特殊样式 */
.ctrlj-download-btn {
    background: rgba(44, 62, 80, 0.9) !important;
    color: #ffffff !important;
    border: 1px solid rgba(44, 62, 80, 0.4) !important;
    box-shadow: 
        0 4px 20px rgba(44, 62, 80, 0.2),
        0 8px 32px rgba(44, 62, 80, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

.ctrlj-download-btn:hover {
    background: rgba(44, 62, 80, 1) !important;
    color: #ffffff !important;
    box-shadow: 
        0 8px 32px rgba(44, 62, 80, 0.25),
        0 16px 48px rgba(44, 62, 80, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

/* Ctrl+J 文档按钮样式 */
.ctrlj-doc-btn {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%) !important;
    color: #ffffff !important;
    box-shadow: 
        0 4px 16px rgba(44, 62, 80, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

.ctrlj-doc-btn:hover {
    box-shadow: 
        0 8px 24px rgba(44, 62, 80, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

/* 图片展示区域*/
.image-gallery {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.image-container {
    width: 100%;
    max-width: 800px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.12),
        0 16px 48px rgba(0, 0, 0, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.image-container.single-image {
    max-width: 900px;
    border-radius: 28px;
}

.image-container:hover {
    transform: translateY(-8px);
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.15),
        0 20px 60px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.gallery-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* 文档区域 */
.documents-section {
    padding: 100px 24px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    position: relative;
}

.documents-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 0, 0, 0.06), transparent);
}

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

.section-title {
    text-align: center;
    font-size: 3rem;
    font-weight: 700;
    color: #1d1d1f;
    margin-bottom: 80px;
    position: relative;
    letter-spacing: -0.02em;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #FAD064, #f0b84d);
    border-radius: 2px;
    box-shadow: 0 2px 8px rgba(250, 208, 100, 0.3);
}

.documents-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 600px;
    margin: 0 auto;
}

/* 应用文档分组样式 */
.app-documents-section {
    margin-bottom: 60px;
}

.app-documents-section:last-child {
    margin-bottom: 0;
}

.app-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 32px;
    text-align: center;
    position: relative;
}

.app-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #3498db, #2980b9);
    border-radius: 2px;
}

.document-card {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 16px;
    padding: 24px 20px;
    text-align: center;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.06),
        0 8px 32px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: 1px solid rgba(0, 0, 0, 0.04);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    position: relative;
    overflow: hidden;
}

.document-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(250, 208, 100, 0.3), transparent);
}

.document-card:hover {
    transform: translateY(-8px);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.08),
        0 16px 48px rgba(0, 0, 0, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.document-icon {
    font-size: 2.2rem;
    margin-bottom: 16px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.document-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1d1d1f;
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.document-description {
    color: #6e6e73;
    margin-bottom: 20px;
    line-height: 1.5;
    font-size: 0.85rem;
}

.document-btn {
    background: linear-gradient(135deg, #FAD064 0%, #f0b84d 100%);
    color: #1d1d1f;
    border: none;
    padding: 10px 20px;
    border-radius: 16px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 
        0 4px 16px rgba(250, 208, 100, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.document-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.document-btn:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 24px rgba(250, 208, 100, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* 文档页面样式 */
.documents-page {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.documents-container {
    display: flex;
    height: 100vh;
    max-width: 1400px;
    margin: 0 auto;
}

/* 左侧文档列表 */
.documents-sidebar {
    width: 300px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-right: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.05);
    overflow-y: auto;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.sidebar-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1d1d1f;
    margin: 0;
}

.close-docs {
    background: none;
    border: none;
    font-size: 20px;
    color: #8e8e93;
    cursor: pointer;
    padding: 8px;
    border-radius: 16px;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.close-docs:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #1d1d1f;
}

.documents-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.doc-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-left: 3px solid transparent;
    margin: 4px 0;
}

.doc-item:hover {
    background: rgba(250, 208, 100, 0.1);
    border-left-color: #FAD064;
}

.doc-item.active {
    background: rgba(250, 208, 100, 0.15);
    border-left-color: #FAD064;
}

.doc-icon {
    font-size: 1.2rem;
    opacity: 0.8;
}

.doc-title {
    font-size: 1rem;
    font-weight: 500;
    color: #1d1d1f;
}

.doc-item.active .doc-title {
    color: #FAD064;
    font-weight: 600;
}

/* 文档分组标题样式 */
.doc-section-header {
    font-size: 0.9rem;
    font-weight: 700;
    color: #8e8e93;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 20px 20px 8px 20px;
    margin-top: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.doc-section-header:first-child {
    margin-top: 0;
}

/* 右侧文档内容 */
.documents-content {
    flex: 1;
    background: white;
    overflow-y: auto;
    padding: 0;
}

.document-content {
    padding: 40px;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
}

/* 文档内容样式 */
.document-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1d1d1f;
    margin-bottom: 32px;
    letter-spacing: -0.02em;
}

.document-content .version-info,
.document-content .terms-content,
.document-content .privacy-content,
.document-content .contact-content {
    line-height: 1.8;
}

.document-content .version-item,
.document-content .section {
    margin-bottom: 32px;
}

.document-content .version-item h3,
.document-content .section h3 {
    color: #FAD064;
    margin-bottom: 16px;
    font-size: 1.4rem;
    font-weight: 600;
}

.document-content .version-item ul,
.document-content .section ul {
    margin-left: 20px;
    margin-top: 12px;
}

.document-content .version-item li,
.document-content .section li {
    margin-bottom: 10px;
}

.document-content .changelog h4 {
    color: #FAD064;
    margin: 20px 0 12px 0;
    font-size: 1.2rem;
}

.document-content .last-updated {
    color: #8e8e93;
    font-style: italic;
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.document-content .contact-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.document-content .contact-item {
    text-align: center;
    padding: 24px;
    background: #f8f9fa;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.document-content .contact-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}

.document-content .response-time {
    color: #8e8e93;
    font-size: 0.9rem;
    margin-top: 8px;
}

.document-content .feedback-section,
.document-content .emergency-contact {
    margin-top: 32px;
    padding: 24px;
    background: #f8f9fa;
    border-radius: 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.document-content .emergency-contact strong {
    color: #e74c3c;
}

/* 页脚样式 */
.footer {
    background: linear-gradient(135deg, #1d1d1f 0%, #2c2c2e 100%);
    color: white;
    text-align: center;
    padding: 20px 24px;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
}

.footer-content p {
    margin: 6px 0;
    font-size: 1rem;
    opacity: 0.9;
    font-weight: 400;
    letter-spacing: 0.01em;
}

.footer-content a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-content a:hover {
    color: #007AFF;
    text-decoration: underline;
}

/* 动画 */

/* 响应式设计 */
@media (max-width: 768px) {
    .app-switcher {
        gap: 12px;
    }
    
    .app-switch-btn {
        padding: 6px 12px;
        gap: 6px;
    }
    
    .app-icon {
        width: 28px;
        height: 28px;
    }
    
    .app-name {
        font-size: 14px;
    }
    
    .nav-menu {
        gap: 16px;
    }
    
    .nav-link {
        font-size: 14px;
        padding: 5px 10px;
    }
    
    .nav-icon-text {
        font-size: 12px;
    }
    
    .main-title {
        font-size: 2.8rem;
    }
    
    .subtitle {
        font-size: 1.3rem;
    }
    
    .ios-download-btn {
        padding: 14px 28px;
        font-size: 1rem;
    }
    
    .image-gallery {
        padding: 0 16px;
    }
    
    .image-container {
        max-width: 100%;
        border-radius: 20px;
    }
    
    .image-container.single-image {
        max-width: 100%;
    }
    
    .documents-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
        max-width: 500px;
    }
    
    .document-card {
        padding: 20px 16px;
        border-radius: 14px;
    }
    
    .document-icon {
        font-size: 2rem;
        margin-bottom: 14px;
    }
    
    .document-title {
        font-size: 1rem;
        margin-bottom: 8px;
    }
    
    .document-description {
        font-size: 0.8rem;
        margin-bottom: 16px;
    }
    
    .document-btn {
        padding: 8px 16px;
        font-size: 0.8rem;
    }
    
    .modal-content {
        margin: 10% auto;
        padding: 32px 24px;
        width: 95%;
        border-radius: 24px;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 16px;
        height: 50px;
    }
    
    .app-switcher {
        gap: 8px;
    }
    
    .app-switch-btn {
        padding: 4px 8px;
        gap: 4px;
    }
    
    .app-icon {
        width: 24px;
        height: 24px;
    }
    
    .app-name {
        font-size: 12px;
    }
    
    .nav-menu {
        gap: 12px;
    }
    
    .nav-link {
        font-size: 13px;
        padding: 4px 8px;
    }
    
    .nav-icon-text {
        font-size: 11px;
    }
    
    .main-title {
        font-size: 2.2rem;
    }
    
    .subtitle {
        font-size: 1.1rem;
    }
    
    .ios-download-btn {
        padding: 12px 24px;
        font-size: 0.95rem;
    }
    
    .btn-icon {
        font-size: 1rem;
    }
    
    .image-gallery {
        padding: 0 8px;
    }
    
    .image-container {
        max-width: 100%;
        border-radius: 16px;
    }
    
    .image-container.single-image {
        max-width: 100%;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .documents-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        max-width: 400px;
    }
    
    .document-card {
        padding: 18px 14px;
        border-radius: 12px;
    }
    
    .document-icon {
        font-size: 1.8rem;
        margin-bottom: 12px;
    }
    
    .document-title {
        font-size: 0.95rem;
        margin-bottom: 6px;
    }
    
    .document-description {
        font-size: 0.75rem;
        margin-bottom: 14px;
    }
    
    .document-btn {
        padding: 8px 14px;
        font-size: 0.75rem;
    }
    
    /* 文档页面响应式 */
    .documents-container {
        flex-direction: column;
    }
    
    .documents-sidebar {
        width: 100%;
        height: auto;
        max-height: 200px;
        border-right: none;
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    }
    
    .documents-content {
        flex: 1;
        height: calc(100vh - 200px);
    }
    
    .document-content {
        padding: 24px;
    }
} 