:root {
    --primary-color: #6366f1;
    --secondary-color: #8b5cf6;
    --accent-color: #f093fb;
    --success-color: #4facfe;
    --text-color: #374151;
    --light-text: #6b7280;
    --card-bg: #ffffff;
    --border-radius: 20px;
    --border-radius-small: 12px;
    --box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --box-shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
    --gradient-bg: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --gradient-card: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-feature1: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-feature2: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --gradient-feature3: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #f8f9ff 0%, #e8ebff 50%, #f0f2ff 100%);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

header {
    text-align: center;
    margin-bottom: 3rem;
    padding-top: 2rem;
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.logo {
    width: 60px;
    height: 60px;
    filter: drop-shadow(0 4px 8px rgba(0, 212, 170, 0.3));
}

.title-section {
    text-align: left;
}

.title-section h1 {
    color: var(--primary-color);
    margin: 0;
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.2;
}

.brand {
    color: var(--secondary-color);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0.2rem 0 0 0;
    opacity: 0.9;
}

.subtitle {
    color: var(--light-text);
    font-size: 1.1rem;
    margin: 0;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .logo-section {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .title-section {
        text-align: center;
    }
    
    .title-section h1 {
        font-size: 1.8rem;
    }
    
    .logo {
        width: 50px;
        height: 50px;
    }
}

header h1 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 3rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

header p {
    color: var(--light-text);
    font-size: 1.2rem;
    font-weight: 400;
}

/* 功能选择器样式 */
.function-selector {
    margin-bottom: 3rem;
}

.function-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.function-card {
    background: var(--card-bg);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    padding: 2rem 1.5rem;
    text-align: center;
    position: relative;
    transition: all 0.3s ease;
    box-shadow: var(--box-shadow);
    cursor: pointer;
    overflow: hidden;
}

.function-card::after {
    content: '';
    position: absolute;
    top: 1rem;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    border: 2px dashed #c7d2fe;
    border-radius: 12px;
    pointer-events: none;
    z-index: 1;
}

.function-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(99, 102, 241, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.function-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
    border-color: var(--primary-color);
}

.function-card:hover::before {
    opacity: 1;
}

.function-card.active {
    border-color: var(--primary-color);
}

.function-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    position: relative;
    z-index: 1;
}

.function-card h3 {
    color: var(--text-color);
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.function-card p {
    color: var(--light-text);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.function-status {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 600;
    z-index: 2;
}

.function-status:not(.coming-soon) {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.function-status.coming-soon {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .function-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
        max-width: 400px;
    }
    
    .function-card {
        padding: 1.5rem 1rem;
    }
    
    .function-icon {
        width: 60px;
        height: 60px;
    }
    
    .function-card h3 {
        font-size: 1.1rem;
    }
}

.upload-area {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 4rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 4rem;
    box-shadow: var(--box-shadow);
    border: none;
    position: relative;
    overflow: hidden;
}

.upload-area::before {
    content: '';
    position: absolute;
    top: 2rem;
    left: 2rem;
    right: 2rem;
    bottom: 2rem;
    border: 2px dashed #c7d2fe;
    border-radius: 16px;
    transition: all 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

.upload-area::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 2;
}

.upload-area:hover::after, .upload-area.dragover::after {
    opacity: 1;
}

.upload-area:hover::before, .upload-area.dragover::before {
    border-color: var(--primary-color);
}

.upload-area:hover, .upload-area.dragover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.upload-area > * {
    position: relative;
    z-index: 2;
}

.upload-icon {
    margin-bottom: 1.5rem;
}

.upload-icon svg {
    fill: var(--primary-color);
    filter: drop-shadow(0 4px 6px rgba(102, 126, 234, 0.3));
}

.upload-area h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.upload-area p {
    color: var(--light-text);
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.file-types {
    font-size: 0.9rem;
    color: var(--light-text);
    opacity: 0.8;
}

.upload-button {
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
    text-decoration-color: transparent;
    transition: text-decoration-color 0.3s ease;
}

.upload-button:hover {
    text-decoration-color: var(--primary-color);
}

/* 功能特点区域 */
.features-section {
    margin-top: 4rem;
    text-align: center;
}

.features-section h2 {
    color: var(--primary-color);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    text-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: var(--box-shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-feature1);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.feature-card:nth-child(2)::before {
    background: var(--gradient-feature2);
}

.feature-card:nth-child(3)::before {
    background: var(--gradient-feature3);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    position: relative;
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
}

.feature-icon.speed {
    background: var(--gradient-feature1);
}

.feature-icon.security {
    background: var(--gradient-feature2);
}

.feature-icon.custom {
    background: var(--gradient-feature3);
}

.feature-icon svg {
    fill: white;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--light-text);
    font-size: 1rem;
    line-height: 1.6;
}

/* 图片变换控制按钮 */
.image-transform-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
    justify-content: center;
}

.transform-button {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: var(--border-radius-small);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(102, 126, 234, 0.3);
    min-width: 80px;
}

.transform-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.4);
}

.transform-button:active {
    transform: translateY(0);
}

.transform-button:first-child {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    box-shadow: 0 2px 4px rgba(107, 114, 128, 0.3);
}

.transform-button:first-child:hover {
    box-shadow: 0 4px 8px rgba(107, 114, 128, 0.4);
}

.image-preview-container {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
}

.image-preview-container:hover {
    box-shadow: var(--box-shadow-hover);
}

.image-preview {
    padding: 2rem;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.preview-header h3 {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-color);
}

.reset-button {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    border: none;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius-small);
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(238, 90, 82, 0.3);
}

.reset-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(238, 90, 82, 0.4);
}

.preview-images {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.original-image, .compressed-image {
    flex: 1;
    min-width: 300px;
}

.original-image h4, .compressed-image h4 {
    margin-bottom: 1rem;
    color: var(--text-color);
}

.image-container {
    border: none;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
}

.image-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.image-info {
    font-size: 0.9rem;
    color: var(--light-text);
}

/* 信息分隔符样式 */
.info-separator {
    color: #8b5cf6;
    font-weight: bold;
    margin: 0 8px;
    text-shadow: 0 0 3px rgba(139, 92, 246, 0.3);
}

/* 压缩率百分比样式 */
.compression-ratio {
    color: #10b981;
    font-weight: bold;
}

/* 裁剪相关样式 */
.crop-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10;
    cursor: crosshair;
}

.crop-box {
    position: absolute;
    border: 2px dashed white;
    background-color: rgba(255, 255, 255, 0.2);
    cursor: move;
    z-index: 11;
}

.resize-handle {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: white;
    border: 1px solid #4a6cf7;
    z-index: 12;
}

.top-left {
    top: -5px;
    left: -5px;
    cursor: nwse-resize;
}

.top-right {
    top: -5px;
    right: -5px;
    cursor: nesw-resize;
}

.bottom-left {
    bottom: -5px;
    left: -5px;
    cursor: nesw-resize;
}

.bottom-right {
    bottom: -5px;
    right: -5px;
    cursor: nwse-resize;
}

.crop-controls {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.crop-button {
    padding: 0.75rem 1.25rem;
    border: none;
    border-radius: var(--border-radius-small);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--gradient-bg);
    color: white;
    box-shadow: 0 4px 6px rgba(102, 126, 234, 0.3);
}

.crop-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(102, 126, 234, 0.4);
}

.crop-button:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 比例选择器样式 */
.aspect-ratio-selector {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    justify-content: space-between;
    flex-wrap: nowrap;
    width: 100%;
}

.aspect-ratio-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    padding: 0.5rem 0.3rem;
    border-radius: var(--border-radius-small);
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid transparent;
    min-width: 50px;
    flex: 1;
    max-width: 70px;
}

.aspect-ratio-option:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
}

.aspect-ratio-option.active {
    background: rgba(102, 126, 234, 0.2);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.ratio-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.free-icon svg {
    color: #e91e63;
}

.ratio-shape {
    border: 2px solid currentColor;
    background: rgba(102, 126, 234, 0.1);
}

.square {
    width: 20px;
    height: 20px;
}

.ratio-2-3 {
    width: 16px;
    height: 24px;
}

.ratio-3-2 {
    width: 24px;
    height: 16px;
}

.ratio-3-4 {
    width: 18px;
    height: 24px;
}

.ratio-4-3 {
    width: 24px;
    height: 18px;
}

.ratio-16-9 {
    width: 28px;
    height: 16px;
}

.ratio-9-16 {
    width: 16px;
    height: 28px;
}

.aspect-ratio-option span {
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
}

.compression-controls {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 2rem;
    border-top: none;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
}

.control-group {
    margin-bottom: 1rem;
}

.control-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

input[type="range"] {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gradient-bg);
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.4);
}

input[type="number"], select {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--border-radius-small);
    font-size: 1rem;
    background: white;
    transition: all 0.3s ease;
}

input[type="number"]:focus, select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.compress-button, .download-button {
    display: block;
    width: 100%;
    padding: 1.25rem;
    border: none;
    border-radius: var(--border-radius-small);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1.5rem;
    position: relative;
    overflow: hidden;
}

.compress-button {
    background: var(--gradient-bg);
    color: white;
    box-shadow: 0 8px 15px rgba(102, 126, 234, 0.3);
}

.compress-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 25px rgba(102, 126, 234, 0.4);
}

.download-button {
    background: var(--gradient-feature1);
    color: white;
    box-shadow: 0 8px 15px rgba(79, 172, 254, 0.3);
}

.download-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 25px rgba(79, 172, 254, 0.4);
}

.download-button:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

footer {
    text-align: center;
    margin-top: 4rem;
    padding: 2rem 0;
    color: var(--light-text);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    header h1 {
        font-size: 2.5rem;
    }
    
    .features-section h2 {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .upload-area {
        padding: 3rem 1.5rem;
    }
    
    .preview-images {
        flex-direction: column;
    }
    
    .original-image, .compressed-image {
        width: 100%;
    }
    
    .image-container {
        height: 200px;
    }
    
    .feature-card {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 1rem 0.5rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .upload-area {
        padding: 2rem 1rem;
    }
    
    .image-preview {
        padding: 1.5rem;
    }
    
    .compression-controls {
        padding: 1.5rem;
    }
}

/* 多图预览容器样式 */
.multi-preview-container {
    display: none;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-top: 2rem;
    overflow: hidden;
}

.multi-image-section {
    padding: 1.5rem;
}

.multi-image-section h4 {
    color: var(--text-color);
    margin-bottom: 1rem;
    font-weight: 600;
}

.multi-image-section .preview-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 1rem;
}

.multi-image-section .image-container {
    position: relative;
    background: #f8f9fa;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.multi-image-section .image-container img {
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
    border-radius: var(--border-radius-small);
}

/* 滚动到控制面板按钮 */
.scroll-to-controls-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0.5rem 0;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.scroll-to-controls-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

.scroll-to-controls-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.3);
}

.scroll-to-controls-button span {
    font-size: 1rem;
}

/* 主页脚样式 */
.main-footer {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    color: #ecf0f1;
    margin: 0;
    padding: 0;
    width: 100%;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem 2rem;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 2rem;
}

.footer-section h4 {
    color: #3498db;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: #3498db;
}

.footer-links a.coming-soon-link {
    color: #95a5a6;
    cursor: not-allowed;
}

.footer-links a.coming-soon-link:hover {
    color: #95a5a6;
}

.footer-email {
    color: #3498db !important;
    font-size: 0.9rem;
    font-weight: 500;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* 品牌区域 */
.brand-section {
    grid-column: span 1;
}

.brand-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.footer-logo-img {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
}

.footer-brand-title {
    color: #3498db;
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
}

.footer-slogan {
    color: #bdc3c7;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
    align-self: flex-start;
}

/* 页脚底部 */
.footer-bottom {
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem 0;
}

.footer-bottom-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
}

.footer-bottom p {
    margin: 0;
    color: #95a5a6;
    font-size: 0.85rem;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    
    .brand-section {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .multi-image-section .preview-images {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .scroll-to-controls-button {
        font-size: 0.8rem;
        padding: 0.6rem 1.2rem;
        gap: 0.4rem;
    }
    
    .scroll-to-controls-button span {
        font-size: 0.9rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        padding: 2rem 1rem 1.5rem;
        gap: 1.5rem;
    }
    
    .brand-section {
        grid-column: span 1;
    }
    
    .footer-logo {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .footer-bottom-content {
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .footer-content {
        padding: 1.5rem 1rem 1rem;
    }
    
    .footer-section h4 {
        font-size: 1rem;
    }
    
    .footer-links a {
        font-size: 0.85rem;
    }
    
    .footer-slogan {
        font-size: 0.85rem;
    }
}

/* ===== 水印功能样式 ===== */

/* 水印容器 */
.watermark-container {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
}

.watermark-container:hover {
    box-shadow: var(--box-shadow-hover);
}

.watermark-preview {
    padding: 2rem;
}

.watermark-tip-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: default;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0.5rem 0;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    pointer-events: none;
    opacity: 0.9;
}

.watermark-tip-button span {
    font-size: 1rem;
}

.watermark-content {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    align-items: stretch;
    min-height: 600px;
}

/* 水印图片区域 */
.watermark-image-section {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.watermark-image-container {
    position: relative;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: var(--border-radius-small);
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
}

.watermark-canvas {
    max-width: 100%;
    max-height: 400px;
    object-fit: contain;
    cursor: crosshair;
}

.watermark-drag-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.watermark-element {
    position: absolute;
    cursor: move;
    user-select: none;
    pointer-events: auto;
    border: 2px dashed rgba(99, 102, 241, 0.5);
    padding: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
}

.watermark-element:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

.watermark-image-info {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--light-text);
    text-align: center;
}

/* 水印控制面板 */
.watermark-controls {
    width: 320px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: var(--border-radius-small);
    padding: 1.5rem;
    height: fit-content;
    align-self: stretch;
    display: flex;
    flex-direction: column;
}

/* 水印标签页 */
.watermark-tabs {
    display: flex;
    margin-bottom: 1.5rem;
    background: white;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.watermark-tab {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 500;
    color: var(--light-text);
    transition: all 0.3s ease;
    position: relative;
}

.watermark-tab.active {
    background: var(--gradient-bg);
    color: white;
}

.watermark-tab:not(.active):hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
}

/* 水印面板 */
.watermark-panel {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.control-group {
    margin-bottom: 1.5rem;
}

.control-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

/* 输入控件 */
.watermark-input, .watermark-select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--border-radius-small);
    font-size: 0.9rem;
    background: white;
    transition: all 0.3s ease;
}

.watermark-input:focus, .watermark-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

/* 字体控件 */
.font-controls {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.font-style-controls {
    display: flex;
    gap: 0.25rem;
}

.font-style-btn {
    width: 32px;
    height: 32px;
    border: 2px solid #e2e8f0;
    background: white;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.font-style-btn:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

.font-style-btn.active {
    background: var(--gradient-bg);
    color: white;
    border-color: var(--primary-color);
}

#fontBold {
    font-family: Arial, sans-serif;
}

#fontItalic {
    font-style: italic;
    font-family: Georgia, serif;
}

/* 颜色选择器 */
.color-palette {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.color-option {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.color-option:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.color-option.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.3);
}

/* 白色选项特殊处理 */
.color-option[data-color="#FFFFFF"] {
    border: 2px solid #e2e8f0;
}

.color-option[data-color="#FFFFFF"].active {
    border: 3px solid var(--primary-color);
}

/* 滑块控件 */
.watermark-slider {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
    margin-top: 0.5rem;
}

.watermark-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gradient-bg);
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(99, 102, 241, 0.3);
    transition: all 0.3s ease;
}

.watermark-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 12px rgba(99, 102, 241, 0.4);
}

.watermark-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gradient-bg);
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(99, 102, 241, 0.3);
    border: none;
}

/* 复选框 */
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkbox-custom {
    width: 20px;
    height: 20px;
    border: 2px solid #e2e8f0;
    border-radius: 4px;
    margin-right: 0.5rem;
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom {
    background: var(--gradient-bg);
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom::after {
    content: '✓';
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* 按钮样式 */
.upload-watermark-btn {
    width: 100%;
    padding: 1rem;
    border: 2px dashed var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
    border-radius: var(--border-radius-small);
    cursor: pointer;
    font-weight: 500;
    color: var(--primary-color);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.upload-watermark-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
}

.download-watermark-btn {
    width: 100%;
    padding: 1.25rem;
    border: none;
    border-radius: var(--border-radius-small);
    background: var(--gradient-bg);
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
    box-shadow: 0 8px 15px rgba(99, 102, 241, 0.3);
}

.download-watermark-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 25px rgba(99, 102, 241, 0.4);
}

.download-watermark-btn:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 水印图片预览 */
.watermark-image-preview {
    position: relative;
    margin-top: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    background: white;
}

.watermark-image-preview img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    display: block;
}

.remove-watermark-btn {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 0, 0, 0.8);
    color: white;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.remove-watermark-btn:hover {
    background: rgba(255, 0, 0, 1);
    transform: scale(1.1);
}

/* 多图水印容器 */
.watermark-multi-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    height: 100%;
    overflow-y: auto;
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--border-radius-small);
    padding: 1rem;
    background: rgba(248, 249, 250, 0.5);
}

/* 水印图片区域高度调整 */
.watermark-image-section {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.watermark-multi-item {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: var(--border-radius-small);
    padding: 1.5rem;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.watermark-multi-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.watermark-multi-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid rgba(99, 102, 241, 0.2);
}

.watermark-multi-item-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
}

.watermark-multi-item-info {
    font-size: 0.9rem;
    color: var(--light-text);
}

.watermark-multi-image-container {
    position: relative;
    background: white;
    border-radius: var(--border-radius-small);
    overflow: hidden;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
}

.watermark-multi-canvas {
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
    cursor: crosshair;
}

.watermark-multi-drag-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.watermark-multi-element {
    position: absolute;
    cursor: move;
    user-select: none;
    pointer-events: auto;
    border: 2px dashed rgba(99, 102, 241, 0.5);
    padding: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.1);
}

.watermark-multi-element:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .watermark-content {
        flex-direction: column;
        gap: 1.5rem;
    }

    .watermark-controls {
        width: 100%;
    }

    .watermark-image-container {
        min-height: 300px;
    }

    .watermark-multi-container {
        max-height: 400px;
    }

    .watermark-multi-image-container {
        min-height: 250px;
    }

    .color-palette {
        grid-template-columns: repeat(4, 1fr);
    }

    .watermark-preview {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .watermark-preview {
        padding: 1rem;
    }

    .watermark-image-container {
        min-height: 250px;
    }

    .color-palette {
        grid-template-columns: repeat(3, 1fr);
    }

    .font-controls {
        flex-direction: column;
        gap: 0.75rem;
        align-items: stretch;
    }
}