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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #e2e8f0;
    background: linear-gradient(135deg, #000000 0%, #0a0a0a 50%, #111111 100%);
    min-height: 100vh;
}

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

/* 头部样式 */
.header {
    padding: 30px 0;
    text-align: center;
    color: white;
}

.header-top {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 15px;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 100%;
    justify-content: space-between;
}

.nav-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* 编辑器页面的简化导航栏 */
.editor-nav .nav-buttons {
    justify-content: flex-start;
    width: 100%;
}

.auth-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-content h1 {
    font-size: 2.5rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    margin: 0;
}

/* 编辑器标题样式 */
.editor-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.editor-logo {
    height: 2em;
}

.editor-brand-text {
    color: gold;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.editor-subtitle {
    font-size: 80%;
    color: #e2e8f0;
}

.header-content h1 i {
    margin-right: 15px;
    color: #ffd700;
}

.header-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 300;
    margin: 0;
}

/* 导航按钮样式 */
.nav-btn {
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    padding: 10px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-btn:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-1px);
}

.pricing-btn:hover {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
}

.pricing-btn.active {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
    cursor: default;
}

.points-btn:hover {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
}

.points-btn.active {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
    cursor: default;
}

.editor-btn:hover {
    background: rgba(255, 215, 0, 0.8);
    border-color: #ffd700;
}

.editor-btn.active {
    background: rgba(255, 215, 0, 0.8);
    border-color: #ffd700;
    cursor: default;
}

.davinci-btn:hover {
    background: rgba(102, 126, 234, 0.8);
    border-color: #667eea;
}

.davinci-btn.active {
    background: rgba(102, 126, 234, 0.8);
    border-color: #667eea;
    cursor: default;
}

/* 语言选择器样式 */
.language-selector {
    position: relative;
}

.language-btn {
    min-width: 120px;
    justify-content: space-between;
}

.language-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border: 1px solid #e2e8f0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    margin-top: 5px;
}

.language-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.language-option {
    padding: 12px 16px;
    color: #4a5568;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
}

.language-option:hover {
    background: #f7fafc;
    color: #667eea;
}

.language-option.active {
    background: #667eea;
    color: white;
}

.language-option.active i {
    opacity: 1;
}

.language-option i {
    opacity: 0;
    font-size: 0.8rem;
}

/* 认证按钮样式 */
.auth-buttons {
    display: flex;
    gap: 15px;
}

.auth-btn {
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.auth-btn:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-2px);
}

.login-btn:hover {
    background: rgba(102, 126, 234, 0.8);
    border-color: #667eea;
}

.register-btn:hover {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
}

.auth-btn i {
    margin-right: 8px;
}

/* 主内容区域 */
.main-content {
    background: rgba(15, 15, 15, 0.9);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    overflow: hidden;
    margin-bottom: 40px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.05);
}

/* 上传区域 */
.upload-section {
    padding: 40px 30px;
    background: linear-gradient(135deg, rgba(5, 5, 5, 0.8) 0%, rgba(10, 10, 10, 0.8) 100%);
}

.upload-area {
    border: 3px dashed rgba(203, 213, 224, 0.3);
    border-radius: 16px;
    padding: 45px 20px;
    text-align: center;
    transition: all 0.3s ease;
    background: rgba(20, 20, 20, 0.7);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.upload-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.5s;
}

.upload-area:hover {
    border-color: #667eea;
    background: rgba(25, 25, 25, 0.8);
    transform: translateY(-2px);
}

.upload-area:hover::before {
    left: 100%;
}

.upload-area.dragover {
    border-color: #667eea;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    transform: scale(1.02);
}

.upload-icon {
    font-size: 3.5rem;
    color: #667eea;
    margin-bottom: 15px;
    display: block;
}

.upload-area.dragover .upload-icon {
    color: white;
}

.upload-content h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.upload-content p {
    color: #a0aec0;
    margin-bottom: 25px;
    font-size: 0.95rem;
}

.upload-area.dragover .upload-content p {
    color: rgba(255,255,255,0.9);
}

.upload-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.upload-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.upload-btn i {
    margin-right: 8px;
}

/* 编辑器区域 */
.editor-section {
    padding: 30px;
}

.editor-container {
    display: grid;
    grid-template-columns: 1fr 240px;
    gap: 15px;
    height: 75vh;
    align-items: stretch;
}

/* 工具栏 */
.toolbar {
    background: rgba(15, 15, 15, 0.9);
    border-radius: 16px;
    padding: 15px;
    border: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(10px);
}

.tool-group {
    margin-bottom: 15px;
}

.tool-group:last-child {
    margin-bottom: 10px;
}

.tool-group h4 {
    display: flex;
    align-items: center;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #e2e8f0;
}

.tool-group h4 i {
    margin-right: 8px;
    color: #667eea;
}

/* 滤镜按钮 */
.filter-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.filter-btn {
    background: rgba(30, 30, 30, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    font-weight: 500;
    color: #e2e8f0;
}

.filter-btn:hover {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.2);
    color: white;
}

.filter-btn.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: #667eea;
}

/* 图片查看控件 */
.view-controls {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.zoom-buttons {
    display: flex;
    gap: 6px;
}

.pan-controls {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.view-btn {
    background: rgba(30, 30, 30, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 6px 8px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    font-weight: 500;
    color: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 1;
}

.view-btn:hover {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.2);
    color: white;
}

.view-btn.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: #667eea;
}

/* 透视校正控件 */
.perspective-controls {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 15px;
}

.perspective-info {
    background: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 15px;
}

.perspective-info p {
    margin: 0;
    font-size: 0.9rem;
    color: #4a5568;
    text-align: center;
}

.perspective-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 15px;
}

.perspective-btn {
    background: rgba(30, 30, 30, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 8px 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #e2e8f0;
}

.perspective-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.perspective-btn.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-color: #667eea;
}

.perspective-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.perspective-btn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
}

#autoPerspective {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

#autoPerspective:hover {
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.perspective-presets h5 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #4a5568;
}

.perspective-presets {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.preset-btn {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    color: #4a5568;
}

.preset-btn:hover {
    background: #e2e8f0;
    border-color: #cbd5e0;
}

.preset-btn.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* 操作按钮 */
.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.action-btn {
    background: rgba(30, 30, 30, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 8px 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #e2e8f0;
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.action-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.action-btn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
}

.reset-btn {
    color: #fc8181;
    border-color: rgba(252, 129, 129, 0.3);
}

.reset-btn:hover {
    background: rgba(229, 62, 62, 0.2);
    border-color: #fc8181;
    color: #fed7d7;
}



.new-btn {
    color: #90cdf4;
    border-color: rgba(144, 205, 244, 0.3);
}

.new-btn:hover {
    background: rgba(102, 126, 234, 0.2);
    border-color: #90cdf4;
    color: #c6d4fd;
}

.download-btn {
    background: linear-gradient(135deg, #48bb78, #38a169);
    color: white;
    border-color: #48bb78;
}

.download-btn:hover {
    background: linear-gradient(135deg, #38a169, #2f855a);
}

.download-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.download-btn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
    background: linear-gradient(135deg, #48bb78, #38a169) !important;
}

.select-photo-btn {
    background: rgba(30, 30, 30, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 8px 10px;
    font-weight: 500;
    font-size: 0.85rem;
    color: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
    width: 100%;
    margin-bottom: 15px;
}

.select-photo-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.2);
    color: #ffffff;
}

.select-photo-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

.select-photo-btn:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
    background: rgba(30, 30, 30, 0.8) !important;
    border-color: rgba(255,255,255,0.1) !important;
    color: #e2e8f0 !important;
}

/* 对比区域 */
.comparison-wrapper {
    background: rgba(18, 18, 18, 0.9);
    border-radius: 16px;
    padding: 15px;
    border: 1px solid rgba(255,255,255,0.05);
    height: 100%;
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(10px);
}

.comparison-wrapper h3 {
    display: flex;
    align-items: center;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #e2e8f0;
    text-align: center;
    justify-content: center;
}

.comparison-wrapper h3 i {
    margin-right: 10px;
    color: #667eea;
}

/* 图片显示容器 - 左侧缩略图，右侧主显示 */
.image-display-container {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    flex: 1;
    flex-direction: column;
}

/* 底部两张缩略图，参考示例中的底部预览 */
.bottom-thumbnails {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 10px;
}
.bottom-thumbnails .thumbnail-item { width: auto; }

/* 缩略图区域 - 垂直布局 */
.thumbnail-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-shrink: 0;
    width: 140px;
}

/* 主显示区域 */
.main-display-area {
    background: transparent; /* 移除主画布背景底框 */
    border-radius: 0;
    padding: 0; /* 取消内边距，避免遮挡底部预览 */
    box-shadow: none;
    text-align: center;
    display: flex;
    align-items: center; /* 垂直居中画布 */
    justify-content: center;
    flex: 0 0 auto; /* 不随内容增高，避免挤压预览 */
    height: 340px; /* 减少高度 */
    backdrop-filter: none;
    border: none;
}

.main-display-canvas {
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
    box-shadow: none;
    background: transparent; /* 画布透明，确保下方预览不被遮住 */
}

.thumbnail-item {
    background: rgba(22, 22, 22, 0.7);
    border-radius: 8px;
    padding: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    backdrop-filter: blur(10px);
}

.thumbnail-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    border-color: #667eea;
}

.thumbnail-item.active {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.2);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.3);
}

.thumbnail-item h4 {
    font-size: 0.7rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: #a0aec0;
    text-align: center;
    line-height: 1.2;
}

.thumbnail-canvas {
    width: 55px;  /* 稍微减小 */
    height: 37px; /* 稍微减小 */
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    background: #f8fafc;
    display: block;
    border: 2px solid #667eea;
}

.image-info {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    backdrop-filter: blur(10px);
}



/* 返回主页按钮 */
.back-to-home {
    text-align: center;
    padding: 25px 0;
}

.back-home-btn {
    background: rgba(102, 126, 234, 0.8);
    border-color: #667eea;
    font-size: 1rem;
    padding: 10px 20px;
}

.back-home-btn:hover {
    background: rgba(102, 126, 234, 1);
    transform: translateY(-2px);
}

/* 底部 */
.footer {
    padding: 25px 0;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.footer-content {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

.contact-info {
    position: absolute;
    right: 20px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .editor-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .toolbar {
        order: 2;
    }
    
    .preview-container {
        order: 1;
        min-height: 400px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
        position: static;
    }
    
    .contact-info {
        position: static;
        text-align: center;
    }
    
    .header-top {
        justify-content: center;
    }
    
    .header-nav {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-buttons {
        order: 1;
    }
    
    .auth-section {
        order: 2;
        justify-content: center;
    }
    
    .auth-buttons {
        justify-content: center;
    }
    
    .header-content h1 {
        font-size: 2rem;
    }
    
    .header-content p {
        font-size: 1rem;
    }
    
    .upload-section {
        padding: 40px 20px;
    }
    
    .editor-section {
        padding: 20px;
    }
    
    .filter-buttons {
        grid-template-columns: 1fr;
    }
    
    .image-display-container {
        flex-direction: column;
    }
    
    .thumbnail-container {
        width: 100%;
        flex-direction: row;
        justify-content: center;
        gap: 15px;
        margin-top: 20px;
    }

    .main-display-area {
        min-height: 300px;
        padding: 15px 20px 10px 20px;
    }

    .main-display-canvas {
        max-height: 260px;
    }

    .bottom-thumbnails {
        margin-top: 5px;
        gap: 8px;
    }

    .thumbnail-item {
        padding: 4px;
    }

    .thumbnail-item h4 {
        font-size: 0.65rem;
        margin-bottom: 2px;
    }

    .thumbnail-canvas {
        width: 50px;
        height: 33px;
    }
}

@media (max-width: 480px) {
    .header-content h1 {
        font-size: 1.8rem;
    }
    
    .upload-area {
        padding: 40px 15px;
    }
    
    .upload-icon {
        font-size: 3rem;
    }
    
    .upload-content h3 {
        font-size: 1.2rem;
    }
    
    .thumbnail-container {
        flex-direction: row;
        gap: 10px;
        justify-content: center;
    }
    
    .thumbnail-item {
        width: 100%;
        max-width: 200px;
        margin: 0 auto;
        padding: 3px;
    }
    
    .bottom-thumbnails {
        margin-top: 3px;
        gap: 6px;
    }
    
    .thumbnail-item h4 {
        font-size: 0.6rem;
        margin-bottom: 1px;
    }
    
    .thumbnail-canvas {
        width: 45px;
        height: 30px;
    }
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 淡入动画 */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* ==================== 认证相关样式 ==================== */

/* 认证按钮样式 */
.auth-btn {
    background: rgba(255,255,255,0.1);
    border: 2px solid rgba(255,255,255,0.3);
    color: white;
    padding: 10px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 6px;
}

.auth-btn:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-2px);
}

.auth-btn:active {
    transform: translateY(0);
}

/* 用户信息样式 */
.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    color: white;
}

.username {
    font-weight: 500;
    color: #ffd700;
}

.username.clickable {
    cursor: pointer;
    transition: color 0.3s ease;
}

.username.clickable:hover {
    color: #ffffff;
    text-decoration: underline;
}

.logout-btn {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

/* 认证模态框样式 */
.auth-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.auth-modal-content {
    background: white;
    padding: 30px;
    border-radius: 16px;
    width: 400px;
    max-width: 90%;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 15px;
}

.auth-modal-header h3 {
    color: #1e293b;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.auth-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #64748b;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.auth-modal-close:hover {
    background: #f1f5f9;
    color: #475569;
}

/* 认证表单样式 */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.auth-field label {
    font-weight: 500;
    color: #374151;
    font-size: 0.9rem;
}

.auth-field input {
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
    background: #f9fafb;
}

.auth-field input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.auth-field input:invalid {
    border-color: #ef4444;
}

/* 认证按钮样式 */
.auth-submit {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.auth-submit:active {
    transform: translateY(0);
}

.auth-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.auth-register {
    background: transparent;
    border: 2px solid #667eea;
    color: #667eea;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.auth-register:hover {
    background: #667eea;
    color: white;
    transform: translateY(-1px);
}

/* 错误和成功消息样式 */
.auth-error {
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 5px;
}

.auth-success {
    color: #10b981;
    font-size: 0.85rem;
    margin-top: 5px;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .auth-modal-content {
        width: 95%;
        padding: 25px 20px;
    }
    
    .auth-modal-header h3 {
        font-size: 1.3rem;
    }
    
    .auth-field input {
        padding: 10px 14px;
    }
    
    .auth-submit {
        padding: 12px 18px;
        font-size: 15px;
    }
    
    .user-info {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}

/* 功能介绍区域 */
.features-section {
    padding: 40px 0;
    background: #1a1a1a;
    color: white;
}

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

.features-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: white;
}

.features-subtitle {
    font-size: 1.1rem;
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
}

.features-list {
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
}

.feature-item {
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.feature-item:last-child {
    border-bottom: none;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.05);
    padding-left: 12px;
    padding-right: 12px;
    margin-left: -12px;
    margin-right: -12px;
    border-radius: 8px;
}

.feature-item h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: white;
}

.feature-item p {
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
}

/* 功能介绍区域响应式设计 */
@media (max-width: 768px) {
    .features-section {
        padding: 30px 0;
    }
    
    .features-title {
        font-size: 1.8rem;
    }
    
    .features-subtitle {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    
    .features-list {
        max-width: 100%;
        padding: 0 10px;
    }
    
    .feature-item {
        padding: 12px 0;
    }
    
    .feature-item:hover {
        padding-left: 8px;
        padding-right: 8px;
        margin-left: -8px;
        margin-right: -8px;
    }
    
    .feature-item h3 {
        font-size: 1.1rem;
    }
    
    .feature-item p {
        font-size: 0.9rem;
    }
}

/* 使用流程区域 */
.how-to-section {
    padding: 40px 0;
    background: #1a1a1a;
    color: white;
}

.how-to-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.how-to-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 35px;
    color: white;
}

.how-to-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    max-width: 1000px;
    margin: 0 auto;
}

.step-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px 15px;
    text-align: center;
    min-width: 180px;
    flex: 1;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.step-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.step-number {
    width: 45px;
    height: 45px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
    margin: 0 auto 12px;
}

.step-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: white;
}

.step-content p {
    font-size: 0.9rem;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
}

.step-arrow {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.3rem;
    margin: 0 8px;
    flex-shrink: 0;
}

/* 使用流程区域响应式设计 */
@media (max-width: 768px) {
    .how-to-section {
        padding: 30px 0;
    }
    
    .how-to-title {
        font-size: 1.8rem;
        margin-bottom: 25px;
    }
    
    .how-to-steps {
        flex-direction: column;
        gap: 12px;
    }
    
    .step-item {
        min-width: auto;
        width: 100%;
        max-width: 280px;
        padding: 15px 12px;
    }
    
    .step-arrow {
        transform: rotate(90deg);
        margin: 3px 0;
    }
    
    .step-number {
        width: 35px;
        height: 35px;
        font-size: 1.1rem;
        margin-bottom: 10px;
    }
    
    .step-content h3 {
        font-size: 1rem;
    }
    
    .step-content p {
        font-size: 0.85rem;
    }
}

/* 常见问题与解答区域 */
.faq-section {
    padding: 40px 0;
    background: #1a1a1a;
    color: white;
}

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

.faq-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 35px;
    color: white;
}

.faq-list {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

.faq-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 20px 25px;
    margin-bottom: 15px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.faq-item:last-child {
    margin-bottom: 0;
}

.faq-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.faq-question {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: white;
    line-height: 1.3;
}

.faq-answer {
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
}

/* 常见问题与解答区域响应式设计 */
@media (max-width: 768px) {
    .faq-section {
        padding: 30px 0;
    }
    
    .faq-title {
        font-size: 1.8rem;
        margin-bottom: 25px;
    }
    
    .faq-list {
        max-width: 100%;
        padding: 0 10px;
    }
    
    .faq-item {
        padding: 15px 18px;
        margin-bottom: 12px;
    }
    
    .faq-question {
        font-size: 1.1rem;
        margin-bottom: 10px;
    }
    
    .faq-answer {
        font-size: 0.9rem;
    }
}

/* 联系与建议区域 */
.contact-section {
    padding: 40px 0;
    background: #1a1a1a;
    color: white;
}

.contact-extra-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.contact-field-with-actions .field-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.contact-field-with-actions label {
    margin: 0;
}

.contact-field-with-actions .contact-extra-actions {
    flex-shrink: 0;
}

.contact-mini-btn {
    padding: 6px 14px;
    font-size: 0.75rem;
    border-width: 1.5px;
    border-radius: 18px;
    min-width: auto;
    transition: none;
}

.contact-mini-btn.points-btn {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
    color: #ffffff;
}

.contact-mini-btn.points-btn:hover {
    background: rgba(72, 187, 120, 0.8);
    border-color: #48bb78;
    transform: none;
}

.contact-mini-btn.logout-btn {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
}

.contact-mini-btn.logout-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: none;
}

.contact-mini-btn i {
    font-size: 0.85rem;
}

.contact-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.contact-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 35px;
    color: white;
}

.contact-form-wrapper {
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

.contact-form {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-field {
    margin-bottom: 20px;
}

.contact-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: white;
    font-size: 1rem;
}

.contact-field input,
.contact-field textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.contact-field input:focus,
.contact-field textarea:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.contact-field input:read-only {
    background: rgba(255, 255, 255, 0.03);
    cursor: not-allowed;
    opacity: 0.7;
}

.contact-field textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-field textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.contact-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.contact-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.contact-submit-btn:active {
    transform: translateY(0);
}

.contact-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.contact-message {
    margin-top: 15px;
    padding: 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    display: none;
}

.contact-message.success {
    display: block;
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.contact-message.error {
    display: block;
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* 联系与建议区域响应式设计 */
@media (max-width: 768px) {
    .contact-section {
        padding: 30px 0;
    }
    
    .contact-mini-btn {
        font-size: 0.75rem;
        padding: 6px 12px;
    }
    
    .contact-field-with-actions .field-label-row {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .contact-field-with-actions .contact-extra-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .contact-title {
        font-size: 1.8rem;
        margin-bottom: 25px;
    }
    
    .contact-form {
        padding: 20px;
    }
    
    .contact-field {
        margin-bottom: 15px;
    }
}

/* 上传区域响应式设计 */
@media (max-width: 768px) {
    .upload-section {
        padding: 30px 20px;
    }
    
    .upload-area {
        padding: 35px 15px;
    }
    
    .upload-icon {
        font-size: 3rem;
        margin-bottom: 12px;
    }
    
    .upload-content h3 {
        font-size: 1.3rem;
        margin-bottom: 6px;
    }
    
    .upload-content p {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
    
    .upload-btn {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
}

/* 校正视界区域 */
.correction-vision-section {
    padding: 40px 0;
    background: #1a1a1a;
    color: white;
}

.correction-vision-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.correction-vision-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: white;
}

.correction-vision-subtitle {
    font-size: 1.1rem;
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
}

.correction-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.gallery-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    min-height: fit-content; /* 确保背景底框高度自适应内容 */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
}

/* 特定图片背景底框高度调整 - 与04_gif保持一致 */
.gallery-item:nth-child(1),  /* 01_gif */
.gallery-item:nth-child(3),  /* 03_gif */
.gallery-item:nth-child(7),  /* 07_gif */
.gallery-item:nth-child(9) { /* 09_gif */
    padding: 15px; /* 与04_gif保持一致的内边距 */
    min-height: fit-content; /* 确保背景底框高度自适应内容 */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}



.gallery-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}



.correction-gif {
    width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 1em; /* 图片与文字的间距为一个文字高度 */
    max-width: 100%;
    display: block;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* 所有图片统一使用1em间距 */
.gallery-item .correction-gif {
    margin-bottom: 1em; /* 图片与文字的间距为一个文字高度 */
}

/* 调整04_gif图片上边距，使其与01_gif文字的距离与07_gif图片上边与04_gif文字的距离相同 */
.gallery-item:nth-child(4) .correction-gif {
    margin-top: 8px; /* 增加04_gif图片的上边距 */
}

.correction-gif:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* 图片点击放大效果 */
.correction-gif.enlarged {
    transform: translate(-50%, -50%) !important;
    z-index: 9999 !important;
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5) !important;
    border-radius: 12px !important;
    margin: 0 !important;
    display: block !important;
}

/* 放大时的容器样式 */
.gallery-item .correction-gif.enlarged {
    transform-origin: center center;
    margin: 20px 0;
}

/* 图片点击提示 */
.gallery-item {
    position: relative;
}

.gallery-item::after {
    content: "点击放大";
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 10;
}

.gallery-item:hover::after {
    opacity: 1;
}

/* 放大时隐藏提示 */
.gallery-item .correction-gif.enlarged + .gallery-caption {
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

/* 背景遮罩样式 */
.image-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9998;
    cursor: pointer;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 放大图片的动画效果 */
.correction-gif.enlarged {
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0.8;
    }
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

.gallery-caption {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    font-weight: 500;
    line-height: 1.4;
    text-align: center;
    width: 100%;
}

/* 所有文字统一样式 */
.gallery-item .gallery-caption {
    line-height: 1.4;
    font-size: 0.95rem;
    text-align: center;
    width: 100%;
}

/* 校正视界区域响应式设计 */
@media (max-width: 768px) {
    .correction-vision-section {
        padding: 30px 0;
    }
    
    .correction-vision-title {
        font-size: 1.8rem;
    }
    
    .correction-vision-subtitle {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    
    .correction-gallery {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 15px;
        padding: 0 10px;
    }
    
    .gallery-item {
        padding: 12px;
        min-height: fit-content; /* 确保背景底框高度自适应内容 */
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
    }
    
    .gallery-caption {
        font-size: 0.9rem;
        text-align: center;
        width: 100%;
    }
    
    /* 平板端统一间距 */
    .gallery-item .correction-gif {
        margin-bottom: 1em; /* 图片与文字的间距为一个文字高度 */
    }
    
    .gallery-item .gallery-caption {
        line-height: 1.4;
        font-size: 0.9rem;
        text-align: center;
        width: 100%;
    }
    
    /* 平板端：调整04_gif图片上边距 */
    .gallery-item:nth-child(4) .correction-gif {
        margin-top: 6px; /* 平板端增加04_gif图片的上边距 */
    }
    

}

@media (max-width: 480px) {
    .correction-gallery {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .gallery-item {
        padding: 10px;
        min-height: fit-content; /* 确保背景底框高度自适应内容 */
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
    }
    
    /* 手机端统一间距 */
    .gallery-item .correction-gif {
        margin-bottom: 1em; /* 图片与文字的间距为一个文字高度 */
    }
    
    .gallery-item .gallery-caption {
        line-height: 1.4;
        font-size: 0.95rem;
        text-align: center;
        width: 100%;
    }
    
    /* 手机端：调整04_gif图片上边距 */
    .gallery-item:nth-child(4) .correction-gif {
        margin-top: 4px; /* 手机端增加04_gif图片的上边距 */
    }
    
    /* 手机端图片放大效果调整 */
    .correction-gif.enlarged {
        transform: translate(-50%, -50%) !important; /* 手机端使用相同的居中定位 */
        animation: zoomInMobile 0.3s ease;
    }
    
    @keyframes zoomInMobile {
        from {
            transform: translate(-50%, -50%) scale(0.8);
            opacity: 0.8;
        }
        to {
            transform: translate(-50%, -50%) scale(1);
            opacity: 1;
        }
    }
    
    /* 手机端隐藏点击提示 */
    .gallery-item::after {
        display: none;
    }
    

}


