/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 上传区域动画 */
#drop-area.highlight {
    border-color: #4299e1;
    background-color: #ebf8ff;
}

/* 图片预览卡片样式 */
.image-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease;
}

.image-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.image-container {
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f9f9f9;
    position: relative;
    overflow: hidden;
}

.image-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: all 0.3s ease;
}

.image-card .original {
    position: absolute;
    top: 4px;
    left: 4px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
}

.image-card .processed {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(34, 197, 94, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
}

.image-info {
    padding: 12px;
}

.image-filename {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.image-dimensions {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 8px;
}

.image-actions {
    display: flex;
    gap: 8px;
}

/* 模式选项样式 */
.mode-option input:checked + i {
    color: #3b82f6;
}

.mode-option input:checked ~ span {
    color: #3b82f6;
    font-weight: 500;
}

.mode-option input:checked + i + span {
    color: #3b82f6;
}

/* 预设尺寸按钮选中状态 */
.preset-size.active {
    background-color: #ebf8ff;
    border-color: #3b82f6;
    color: #3b82f6;
    font-weight: 500;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.image-card {
    animation: fadeIn 0.3s ease forwards;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .image-container {
        height: 160px;
    }
}

@media (max-width: 640px) {
    .image-actions {
        flex-direction: column;
    }
    
    .image-actions button {
        width: 100%;
    }
}
