        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        
        body {
            font-family: 'Microsoft YaHei', Arial, sans-serif;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            min-height: 100vh;
            padding: 20px;
        }
        
        .container {
            max-width: 1600px;
            margin: 0 auto;
            background: white;
            border-radius: 20px;
            box-shadow: 0 20px 60px rgba(0,0,0,0.3);
            padding: 40px;
        }
        
        h1 {
            text-align: center;
            color: #333;
            margin-bottom: 30px;
            font-size: 2.5em;
        }
        
        .upload-area {
            border: 3px dashed #667eea;
            border-radius: 15px;
            padding: 0;
            text-align: center;
            background: #f8f9ff;
            cursor: pointer;
            transition: all 0.3s;
            margin-bottom: 30px;
        }
        
        .upload-area:hover {
            border-color: #764ba2;
            background: #f0f2ff;
        }
        
        .upload-area.dragover {
            border-color: #764ba2;
            background: #e8ebff;
        }
        
        #fileInput {
            display: none;
        }
        
        .upload-icon {
            font-size: 64px;
            color: #667eea;
            margin-bottom: 20px;
        }
        
        .upload-text {
            font-size: 18px;
            color: #666;
            margin-bottom: 10px;
        }
        
        /* 三列布局 */
        .preview-container {
            display: none;
            grid-template-columns: 1fr 1fr 1fr;
            gap: 20px;
            margin: 30px 0;
        }
        
        .preview-column {
            background: #f8f9ff;
            border-radius: 15px;
            padding: 20px;
            min-height: 400px;
        }
        
        .preview-column h3 {
            text-align: center;
            color: #333;
            margin-bottom: 15px;
            font-size: 1.2em;
        }
        
        .image-info {
            text-align: center;
            color: #666;
            font-size: 13px;
            margin-top: 10px;
            padding: 8px;
            background: #f5f5f5;
            border-radius: 5px;
        }
        
        .image-info-line {
            margin: 4px 0;
        }
        
        .process-controls {
            margin-top: 15px;
            text-align: center;
        }
        
        .width-input-group {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            margin-bottom: 10px;
        }
        
        .width-input {
            padding: 8px 12px;
            border: 2px solid #667eea;
            border-radius: 8px;
            font-size: 14px;
            width: 100px;
            text-align: center;
        }
        
        .width-input:focus {
            outline: none;
            border-color: #764ba2;
        }
        
        .width-unit {
            font-size: 14px;
            color: #666;
        }
        
        .process-tip {
            font-size: 12px;
            color: #999;
            margin-top: 8px;
            line-height: 1.5;
        }
        
        .preview-image {
            width: 100%;
            box-shadow: 0 5px 15px rgba(0,0,0,0.1);
            background: #fff;
        }
        
        /* 颜色映射表 */
        .color-mapping-list {
            max-height: 600px;
            overflow-y: auto;
        }
        
        .color-item {
            display: flex;
            align-items: center;
            padding: 10px;
            margin-bottom: 8px;
            background: white;
            border-radius: 8px;
            border: 1px solid #e0e0e0;
        }
        
        .color-item.transparent {
            background: repeating-linear-gradient(
                45deg,
                #f0f0f0,
                #f0f0f0 10px,
                #e0e0e0 10px,
                #e0e0e0 20px
            );
        }
        
        .color-preview {
            width: 40px;
            height: 40px;
            border-radius: 5px;
            border: 2px solid #ddd;
            margin-right: 10px;
            flex-shrink: 0;
        }
        
        .color-info {
            flex: 1;
            min-width: 0;
        }
        
        .color-rgb {
            font-size: 12px;
            color: #666;
            margin-bottom: 4px;
        }
        
        .color-count {
            font-size: 11px;
            color: #999;
        }
        
        .color-select {
            padding: 6px 10px;
            border: 1px solid #ddd;
            border-radius: 5px;
            font-size: 14px;
            cursor: pointer;
            min-width: 120px;
        }
        
        .color-actions {
            display: flex;
            align-items: center;
            gap: 10px;
        }
        
        .btn-replace {
            padding: 6px 12px;
            background: #667eea;
            color: white;
            border: none;
            border-radius: 5px;
            font-size: 12px;
            cursor: pointer;
            transition: all 0.3s;
        }
        
        .btn-replace:hover {
            background: #764ba2;
        }
        
        .replaced-color {
            width: 30px;
            height: 30px;
            border-radius: 5px;
            border: 2px solid #ddd;
        }
        
        /* Modal样式 */
        .modal {
            display: none;
            position: fixed;
            z-index: 1000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0,0,0,0.5);
            overflow: auto;
        }
        
        .modal-content {
            background-color: #fefefe;
            margin: 5% auto;
            padding: 30px;
            border-radius: 15px;
            width: 90%;
            max-width: 800px;
            max-height: 80vh;
            overflow-y: auto;
        }
        
        .modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 20px;
        }
        
        .modal-header h2 {
            margin: 0;
            color: #333;
        }
        
        .close {
            color: #aaa;
            font-size: 28px;
            font-weight: bold;
            cursor: pointer;
        }
        
        .close:hover {
            color: #000;
        }
        
        .color-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
            gap: 15px;
            margin-top: 20px;
        }
        
        .color-option {
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 10px;
            border: 2px solid #ddd;
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.3s;
        }
        
        .color-option:hover {
            border-color: #667eea;
            transform: translateY(-2px);
            box-shadow: 0 4px 8px rgba(0,0,0,0.1);
        }
        
        .color-option.selected {
            border-color: #667eea;
            background: #f0f2ff;
        }
        
        .color-option-preview {
            width: 60px;
            height: 60px;
            border-radius: 5px;
            border: 2px solid #ddd;
            margin-bottom: 8px;
        }
        
        .color-option-label {
            font-size: 12px;
            font-weight: bold;
            color: #333;
            margin-bottom: 4px;
        }
        
        .color-option-rgb {
            font-size: 11px;
            color: #666;
        }
        
        .btn {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            border: none;
            padding: 15px 40px;
            font-size: 18px;
            border-radius: 50px;
            cursor: pointer;
            transition: all 0.3s;
            margin: 10px;
            box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
        }
        
        .btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 20px rgba(102, 126, 234, 0.6);
        }
        
        .btn:disabled {
            background: #ccc;
            cursor: not-allowed;
            transform: none;
        }
        
        .btn-download {
            background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
            box-shadow: 0 5px 15px rgba(40, 167, 69, 0.4);
        }
        
        .btn-download:hover {
            box-shadow: 0 8px 20px rgba(40, 167, 69, 0.6);
        }
        
        .options-container {
            background: #f8f9ff;
            border-radius: 15px;
            padding: 20px;
            margin: 30px 0;
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            align-items: center;
            gap: 30px;
        }
        
        .option-group {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 8px;
        }
        
        .option-label {
            font-size: 14px;
            color: #666;
            font-weight: 500;
        }
        
        .option-select {
            padding: 8px 15px;
            border: 2px solid #667eea;
            border-radius: 8px;
            background: white;
            font-size: 14px;
            color: #333;
            cursor: pointer;
            min-width: 120px;
        }
        
        .option-select:disabled {
            background: #f5f5f5;
            border-color: #ddd;
            color: #999;
            cursor: not-allowed;
        }
        
        .option-select:focus {
            outline: none;
            border-color: #764ba2;
        }
        
        .btn-container {
            text-align: center;
            margin: 30px 0;
        }
        
        .loading-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.5);
            z-index: 10000;
            justify-content: center;
            align-items: center;
        }
        
        .loading-overlay.active {
            display: flex;
        }
        
        .loading-message {
            background: white;
            padding: 30px 50px;
            border-radius: 15px;
            font-size: 18px;
            color: #333;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
            text-align: center;
            min-width: 300px;
        }
        
        .loading-progress {
            margin-top: 20px;
            width: 100%;
            height: 30px;
            background: #f0f0f0;
            border-radius: 15px;
            overflow: hidden;
            position: relative;
        }
        
        .loading-progress-bar {
            height: 100%;
            background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
            width: 0%;
            min-width: 0%;
            transition: width 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 14px;
            font-weight: bold;
            box-sizing: border-box;
        }
        
        .loading-progress-text {
            margin-top: 10px;
            font-size: 14px;
            color: #666;
        }
        
        .maintenance-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(255, 255, 255, 0.9);
            z-index: 99999;
            justify-content: center;
            align-items: center;
        }
        
        .maintenance-overlay.active {
            display: flex;
        }
        
        .maintenance-message {
            text-align: center;
            padding: 40px 60px;
            background: white;
            border-radius: 15px;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
        }
        
        .maintenance-message h2 {
            font-size: 28px;
            color: #333;
            margin-bottom: 15px;
        }
        
        .maintenance-message p {
            font-size: 18px;
            color: #666;
            margin: 10px 0;
        }
        
        /* 进程限制弹框样式 */
        .process-limit-modal {
            display: none;
            position: fixed;
            z-index: 10000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0,0,0,0.6);
            overflow: auto;
        }
        
        .process-limit-modal.active {
            display: flex;
            justify-content: center;
            align-items: center;
        }
        
        .process-limit-content {
            background-color: #fff;
            margin: auto;
            padding: 40px;
            border-radius: 15px;
            width: 90%;
            max-width: 600px;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
            text-align: center;
        }
        
        .process-limit-content h2 {
            font-size: 24px;
            color: #333;
            margin-bottom: 20px;
        }
        
        .process-limit-content p {
            font-size: 16px;
            color: #666;
            line-height: 1.6;
            margin: 15px 0;
        }
        
        .process-limit-content .close-btn {
            margin-top: 30px;
            padding: 12px 40px;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            border: none;
            border-radius: 25px;
            font-size: 16px;
            cursor: pointer;
            transition: all 0.3s;
        }
        
        .process-limit-content .close-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
        }
        
        .description-text {
            text-align: center;
            color: #666;
            font-size: 14px;
            margin-bottom: 20px;
            line-height: 1.6;
        }
        
        .download-tip {
            text-align: center;
            color: #666;
            font-size: 13px;
            margin: 10px 0;
            padding: 0 20px;
            line-height: 1.6;
        }
        
        .status {
            text-align: center;
            padding: 15px;
            margin: 20px 0;
            border-radius: 10px;
            display: none;
        }
        
        .status.info {
            background: #e3f2fd;
            color: #1976d2;
        }
        
        .status.success {
            background: #e8f5e9;
            color: #388e3c;
        }
        
        .status.error {
            background: #ffebee;
            color: #d32f2f;
        }
        
        .progress {
            width: 100%;
            height: 30px;
            background: #f0f0f0;
            border-radius: 15px;
            overflow: hidden;
            margin: 20px 0;
            display: none;
        }
        
        .progress-bar {
            height: 100%;
            background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
            width: 0%;
            transition: width 0.3s;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
        }
        
        /* 加载动画 */
        .loading {
            text-align: center;
            padding: 40px;
            color: #666;
        }