* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #2e3351 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 20px;
    background: white;
    min-height: 100vh;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
}

header {
    text-align: center;
    margin-bottom: 0px;
    padding-bottom: 0px;
    border-bottom: 2px solid #f0f0f0;
}

header h1 {
    color: #ffffff;
    margin-bottom: 10px;
}

header p {
    color: #ffffff;
    font-size: 1.1em;
}

/* 主标题样式 */
.main-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 30px;
    color: white;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
}

.main-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
    transform: rotate(30deg);
}

.header-content {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    /*border: 2px solid rgba(255, 255, 255, 0.3);*/
}

.logo-text h1 {
    font-size: 1.5em;
    margin: 0 0 5px 0;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.logo-text p {
    font-size: 0.9em;
    margin: 0;
    opacity: 0.9;
    font-weight: 500;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-badges {
    display: flex;
    gap: 8px;
}

.badge {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.hamburger-menu {
    display: none;
    font-size: 24px;
    cursor: pointer;
    padding: 5px;
    border-radius: 5px;
}

.hamburger-menu:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mobile-menu {
    display: none;
    padding-top: 15px;
}

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* 桌面版导航 */
.desktop-nav {
    display: flex;
}

/* 功能导航栏样式 */
.feature-nav {
    display: flex;
    gap: 5px;
    margin: 10px 0;
    padding: 10px 5px;
    background: #f7fafc;
    border-radius: 16px;
    overflow-x: auto;
    position: relative;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 20px;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 90px;
    /*background: white;
    border: 2px solid #e2e8f0;*/
    position: relative;
    z-index: 1;
    flex: 1;
    min-width: 0; /* 允许flex项目缩小到内容大小以下 */
}

.nav-item:hover {
    background: #f0f7ff;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.15);
}

.nav-item.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.25);
}

.nav-item i {
    font-size: 24px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.nav-item.active i {
    color: white;
}

.nav-item span {
    font-size: 0.65rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-item.active span {
    color: white;
}

/* 通用区域标题样式 */
.section-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
    
    padding-top: 8px;
}

.section-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.section-icon i {
    font-size: 24px;
    color: white;
}

.section-title h2 {
    margin: 0 0 5px 0;
    color: #2d3748;
    font-size: 1.5em;
    font-weight: 600;
}

.section-title p {
    margin: 0;
    color: #718096;
    font-size: 0.95em;
}

/* 功能区域样式 */
.feature-section {
    display: none;
}

.feature-section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}


@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 上传区域样式 */
.upload-section {
    margin-bottom: 30px;
}

.upload-area {
    border: 3px dashed #cbd5e0;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafafa;
}

.upload-area:hover {
    border-color: #667eea;
    background: #f0f7ff;
}

.upload-placeholder .upload-icon {
    font-size: 48px;
    margin-bottom: 15px;
    display: block;
}

.upload-placeholder p {
    font-size: 1.2em;
    margin-bottom: 10px;
    color: #4a5568;
}

.upload-placeholder small {
    color: #718096;
}

.preview-area {
    position: relative;
    margin-top: 20px;
    text-align: center;
}

#imagePreview {
    max-width: 100%;
    max-height: 400px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.remove-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #e53e3e;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    font-size: 18px;
}

.question-section {
    margin-bottom: 30px;
}

.question-section label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #4a5568;
}

#analyzeQuestionInput,
#colorizePrompt,
#paletteColorizePrompt,
#inpaintingPrompt,
#outpaintingPrompt {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    resize: vertical;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    font-family: inherit;
    min-height: 100px;
}

#analyzeQuestionInput:focus,
#colorizePrompt:focus,
#paletteColorizePrompt:focus,
#inpaintingPrompt:focus,
#outpaintingPrompt:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

#questionInput {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    resize: vertical;
    transition: border-color 0.3s ease;
}

#questionInput:focus {
    outline: none;
    border-color: #667eea;
}

.colorization-section {
    margin-bottom: 20px;
    padding: 15px;
    background: #f7fafc;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.colorization-section label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #4a5568;
}

#colorizationMode {
    width: 100%;
    padding: 10px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    background: white;
}

.action-section {
    text-align: center;
    margin-bottom: 30px 0px;
}

#analyzeImageBtn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 14px 36px;
    font-size: 16px;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

#analyzeImageBtn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

#analyzeImageBtn:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

#analyzeImageBtn:active:not(:disabled) {
    transform: translateY(0);
}

/* 为其他功能按钮添加类似样式 */
#startColorizeBtn,
#startPaletteColorizeBtn,
#startInpaintingBtn,
#startOutpaintingBtn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 14px 36px;
    font-size: 16px;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

#startColorizeBtn:hover:not(:disabled),
#startPaletteColorizeBtn:hover:not(:disabled),
#startInpaintingBtn:hover:not(:disabled),
#startOutpaintingBtn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

#startColorizeBtn:disabled,
#startPaletteColorizeBtn:disabled,
#startInpaintingBtn:disabled,
#startOutpaintingBtn:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

#startColorizeBtn:active:not(:disabled),
#startPaletteColorizeBtn:active:not(:disabled),
#startInpaintingBtn:active:not(:disabled),
#startOutpaintingBtn:active:not(:disabled) {
    transform: translateY(0);
}

#analyzeBtn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 36px;
    font-size: 16px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#analyzeBtn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

#analyzeBtn:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
}

.result-section {
    background: #f7fafc;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 30px;
    border-left: 4px solid #667eea;
}

.result-section h3 {
    color: #4a5568;
    margin-bottom: 16px;
}

.result-content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 16px;
    line-height: 1.8;
    border: 1px solid #e2e8f0;
}

.result-meta {
    text-align: right;
    color: #718096;
    font-size: 0.9em;
}

.loading-section {
    text-align: center;
    padding: 40px;
}

.loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

footer {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e2e8f0;
    color: #718096;
}

footer a {
    color: #667eea;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* 页脚样式 */
.main-footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e2e8f0;
    background: #f7fafc;
    border-radius: 12px;
    padding: 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-info p {
    margin: 0 0 5px 0;
    color: #718096;
    font-size: 0.95em;
}

.footer-info a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-info a:hover {
    color: #5a67d8;
    text-decoration: underline;
}

.footer-note {
    font-size: 0.85em;
    color: #a0aec0;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: #718096;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #667eea;
}

/* 色板样式 */
.color-palette {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
    padding: 15px;
    background: #ffffff;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.color-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 10px;
}

.color-box {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    border: 2px solid #ddd;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 5px;
}

.color-value {
    font-size: 0.8em;
    color: #4a5568;
    text-align: center;
    word-break: break-all;
    max-width: 60px;
}

/* 上色模式選擇器 */
.mode-selector {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    padding: 20px;
    background: #f7fafc;
    border-radius: 12px;
}

.mode-option {
    flex: 1;
    padding: 20px;
    text-align: center;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.mode-option:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.mode-option.active {
    border-color: #667eea;
    background: #f0f7ff;
}

.mode-option i {
    display: block;
    font-size: 32px;
    color: #667eea;
    margin-bottom: 10px;
}

.mode-option span {
    font-weight: 600;
    color: #4a5568;
}

/* 風格預設 */
.style-presets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.preset-option {
    background: white;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.preset-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.preset-option.active {
    border-color: #667eea;
    background: #f0f7ff;
}

.preset-icon {
    width: 50px;
    height: 50px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    font-size: 20px;
}

.preset-option span {
    display: block;
    font-weight: 500;
    color: #4a5568;
}

/* 編輯模式選擇器 */
.edit-mode-selector {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
}

.edit-mode-option {
    flex: 1;
    padding: 20px;
    text-align: center;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
}

.edit-mode-option:hover {
    border-color: #667eea;
}

.edit-mode-option.active {
    border-color: #667eea;
    background: #f0f7ff;
}

.edit-mode-option i {
    display: block;
    font-size: 32px;
    color: #667eea;
    margin-bottom: 10px;
}

.edit-mode-option span {
    font-weight: 600;
    color: #4a5568;
}

/* 編輯界面 */
.edit-interface {
    background: #f7fafc;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
}

.edit-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.edit-upload-area {
    background: white;
    border-radius: 8px;
    padding: 20px;
}

.edit-upload-area .upload-area {
    border: 2px dashed #cbd5e0;
    border-radius: 8px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-upload-area .upload-area:hover {
    border-color: #667eea;
    background: #f0f7ff;
}

.edit-upload-area .upload-area i {
    font-size: 48px;
    color: #667eea;
    margin-bottom: 15px;
}

.edit-upload-area .upload-area p {
    margin: 0;
    font-weight: 500;
    color: #4a5568;
}

.edit-instructions, .outpainting-options {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.outpainting-container {
    margin-bottom: 30px;
}

.coming-soon {
    text-align: center;
    padding: 60px;
    color: #718096;
}

.coming-soon i {
    font-size: 64px;
    margin-bottom: 20px;
    color: #cbd5e0;
}

.coming-soon h3 {
    margin-bottom: 10px;
    color: #4a5568;
}

/* 圖片檢查結果 */
.suitability-check {
    background: #f0fff4;
    border: 1px solid #9ae6b4;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.suitability-result {
    background: white;
    border-radius: 6px;
    padding: 15px;
}

.suitability-score {
    display: inline-block;
    padding: 8px 20px;
    background: #38a169;
    color: white;
    border-radius: 20px;
    font-weight: bold;
    margin-bottom: 15px;
}

.suitability-details {
    margin-top: 15px;
}

.suitability-details ul {
    padding-left: 20px;
    margin-bottom: 15px;
}

.suitability-details li {
    margin-bottom: 5px;
    color: #4a5568;
}

img {
    max-width: 100%;
    height: auto;
}

/* 复选框样式 */
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 15px;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkbox-custom {
    width: 20px;
    height: 20px;
    border: 2px solid #cbd5e0;
    border-radius: 4px;
    margin-right: 10px;
    position: relative;
    transition: all 0.3s ease;
}

.checkbox-label:hover .checkbox-custom {
    border-color: #667eea;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom {
    background: #667eea;
    border-color: #667eea;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
}

.checkbox-text {
    color: #4a5568;
    font-weight: 500;
}

/* 色板选择器样式 */
.palette-selector {
    background: #f7fafc;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 30px;
    border-left: 4px solid #667eea;
}

.palette-selector h3 {
    color: #4a5568;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.palette-selector .palette-actions {
    text-align: center;
    margin-top: 20px;
}

.palette-selector .palette-actions button {
    padding: 10px 20px;
    border: 2px solid #667eea;
    background: white;
    color: #667eea;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.palette-selector .palette-actions button:hover {
    background: #667eea;
    color: white;
}

/* 色板项目样式 */
.palette-item {
    background: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid #e2e8f0;
    position: relative;
    overflow: hidden;
}

.palette-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-color: #667eea;
}

.palette-item.selected {
    border-color: #667eea;
    background: #f0f7ff;
}

.palette-preview {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 10px;
    display: block;
}

.palette-colors {
    display: flex;
    gap: 5px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.palette-color {
    flex: 1;
    min-width: 30px;
    height: 30px;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

.palette-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85em;
    color: #718096;
}

.palette-date {
    font-weight: 500;
}

/* 已选色板预览 */
.palette-preview-container {
    background: white;
    border-radius: 8px;
    padding: 15px;
    border: 1px solid #e2e8f0;
}

.palette-preview-container h4 {
    margin: 0 0 10px 0;
    color: #4a5568;
    font-size: 1em;
}

.selected-palette-colors {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.selected-palette-color {
    width: 30px;
    height: 30px;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

/* 格式化结果样式 */
.formatted-result {
    line-height: 1.8;
    font-size: 1em;
}

.formatted-result p {
    margin-bottom: 15px;
    line-height: 1.6;
}

.formatted-result h1 {
    font-size: 1.5em;
    color: #4a5568;
    margin: 20px 0 10px 0;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 5px;
}

.formatted-result h2 {
    font-size: 1.3em;
    color: #4a5568;
    margin: 18px 0 8px 0;
}

.formatted-result h3 {
    font-size: 1.1em;
    color: #4a5568;
    margin: 16px 0 6px 0;
}

.formatted-result ul {
    margin: 10px 0 10px 20px;
    list-style-type: disc;
}

.formatted-result li {
    margin-bottom: 5px;
    line-height: 1.5;
}

/* 历史记录样式 */
.history-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.history-item {
    background: white;
    border-radius: 8px;
    padding: 20px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.history-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e2e8f0;
}

.history-header h4 {
    margin: 0;
    color: #4a5568;
    font-size: 1em;
    flex: 1;
}

.history-date {
    font-size: 0.8em;
    color: #718096;
    white-space: nowrap;
    margin-left: 10px;
}

.history-content {
    margin-bottom: 15px;
}

.history-result p {
    margin: 0 0 10px 0;
    line-height: 1.5;
    color: #4a5568;
    font-size: 0.9em;
}

.history-palette {
    margin-top: 10px;
}

.history-palette p {
    margin: 0 0 8px 0;
    font-weight: 500;
    color: #4a5568;
    font-size: 0.9em;
}

.history-actions {
    text-align: right;
}

.history-actions .secondary-btn {
    padding: 6px 12px;
    font-size: 0.85em;
}

.no-history {
    text-align: center;
    padding: 60px 20px;
    color: #718096;
}

.no-history i {
    font-size: 48px;
    margin-bottom: 15px;
    display: block;
    color: #cbd5e0;
}

.no-history p {
    margin: 10px 0;
    font-size: 1.1em;
}

.no-history .subtext {
    font-size: 0.9em;
    color: #a0aec0;
}

.history-actions {
    text-align: right;
    margin-top: 15px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        margin: 0;
        padding: 15px;
        box-shadow: none;
    }
    
    /* 移动端标题样式优化 */
    .main-header {
        padding: 15px;
        border-radius: 12px;
    }
    
    .header-content {
        flex-wrap: wrap;
    }
    
    .logo-container {
        gap: 10px;
    }
    
    .logo {
        width: 50px;
        height: 50px;
    }
    
    .logo-text h1 {
        font-size: 1.2em;
    }
    
    .logo-text p {
        font-size: 0.8em;
    }
    
    .header-right {
        display: none;
    }
    
    .hamburger-menu {
        display: block;
    }
    
    .desktop-nav {
        display: none;
    }
    
    .mobile-menu {
        display: block;
        padding-top: 15px;
    }
    
    .mobile-nav {
        display: flex;
        flex-direction: column;
        gap: 8px;
        max-height: 300px;
        overflow-y: auto;
    }
    
    .mobile-nav .nav-item {
        width: 100%;
        min-width: auto;
        padding: 12px 15px;
    }
    
    .feature-nav {
        display: none; /* 在移动端隐藏桌面版导航 */
    }
    
    .nav-item {
        padding: 12px 15px;
        min-width: 80px;
    }
    
    .nav-item span {
        font-size: 0.6em;
    }
    
    .section-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .section-icon {
        width: 50px;
        height: 50px;
        margin: 0 auto 10px;
    }
    
    .section-title h2 {
        font-size: 1.3em;
    }
    
    .section-title p {
        font-size: 0.85em;
    }
    
    footer {
        padding: 15px 10px;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .footer-links {
        width: 100%;
        justify-content: center;
    }
    
    .history-grid {
        grid-template-columns: 1fr;
    }
    
    .edit-container {
        grid-template-columns: 1fr;
    }
    
    .style-presets {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .mode-selector, .edit-mode-selector {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .main-header {
        padding: 10px;
    }
    
    .logo-container {
        gap: 8px;
    }
    
    .logo {
        width: 45px;
        height: 45px;
    }
    
    .logo-text h1 {
        font-size: 1.1em;
    }
    
    .logo-text p {
        font-size: 0.75em;
        display: none;
    }
    
    .mobile-nav .nav-item {
        padding: 12px 10px;
    }
    
    .nav-item {
        padding: 10px 12px;
        min-width: 70px;
    }
    
    .nav-item i {
        font-size: 20px;
    }
    
    .nav-item span {
        font-size: 0.55em;
    }
    
    .section-header {
        margin-bottom: 20px;
    }
    
    .section-icon {
        width: 45px;
        height: 45px;
    }
    
    .section-title h2 {
        font-size: 1.2em;
    }
}