.template-canvas-container{display:flex;flex-direction:column;align-items:center}.template-canvas{border:1px solid #e0e0e0;border-radius:4px;box-shadow:0 4px 12px #0000001a;cursor:pointer;max-width:100%;height:auto}.canvas-info{margin-top:1rem;padding:.75rem 1rem;background-color:#f5f5f5;border-radius:6px;text-align:center}.canvas-info p{color:#666;font-size:.875rem;margin:0}.template-thumbnail-canvas{width:100%;height:180px;display:flex;align-items:center;justify-content:center;background:#fafafa}.template-thumbnail-canvas canvas{max-width:100%;max-height:100%;box-shadow:0 2px 4px #0000001a;border-radius:2px}.template-thumbnail-loading{width:100%;height:180px;display:flex;align-items:center;justify-content:center;background:#fafafa}.spinner{width:30px;height:30px;border:3px solid rgba(102,126,234,.2);border-top-color:#667eea;border-radius:50%;animation:spin .8s linear infinite}.template-thumbnail-error{width:100%;height:180px;display:flex;align-items:center;justify-content:center;background:#fafafa;color:#999}.template-thumbnail-error svg{width:40px;height:40px;opacity:.5}.template-thumbnail-placeholder{width:100%;height:180px;display:flex;align-items:center;justify-content:center;background:linear-gradient(135deg,#667eea,#764ba2);color:#fff}.template-thumbnail-placeholder svg{width:60px;height:60px}.upload-container{background:#fff;border-radius:8px;padding:2rem;box-shadow:0 2px 8px #0000001a;margin-bottom:2rem}.upload-container h3{margin-top:0;margin-bottom:1.5rem;font-size:1.5rem;color:#333}.upload-form{display:flex;flex-direction:column;gap:1.5rem}.drop-zone{border:2px dashed #ccc;border-radius:8px;padding:3rem 2rem;text-align:center;transition:all .3s;cursor:pointer;background:#fafafa}.drop-zone.drag-active{border-color:#667eea;background:#f0f4ff}.drop-zone.has-file{border-color:#4caf50;background:#f1f8f4}.file-input{display:none}.drop-zone-label{display:flex;flex-direction:column;align-items:center;gap:1rem;cursor:pointer}.upload-icon{width:64px;height:64px;color:#667eea}.drop-zone-label p{margin:0;color:#666}.file-types{font-size:.875rem;color:#999}.file-selected{display:flex;align-items:center;gap:1rem;padding:1rem;background:#fff;border-radius:6px}.file-icon{width:48px;height:48px;color:#4caf50;flex-shrink:0}.file-info{flex:1;text-align:left}.file-name{font-weight:600;color:#333;margin:0 0 .25rem}.file-size{font-size:.875rem;color:#666;margin:0}.remove-file-btn{width:32px;height:32px;border-radius:50%;border:none;background:#f44336;color:#fff;font-size:1.5rem;cursor:pointer;display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:background .2s}.remove-file-btn:hover{background:#d32f2f}.form-group{display:flex;flex-direction:column;gap:.5rem}.form-group label{font-weight:600;color:#333;font-size:.95rem}.form-group input,.form-group textarea,.form-group select{padding:.75rem;border:1px solid #ddd;border-radius:6px;font-size:1rem;font-family:inherit;transition:border-color .2s}.form-group input:focus,.form-group textarea:focus,.form-group select:focus{outline:none;border-color:#667eea}.template-type-select{cursor:pointer;background-color:#fff}.field-hint{margin-top:.5rem;font-size:.85rem;color:#666;line-height:1.4}.form-group textarea{resize:vertical}.error-message{padding:1rem;background:#ffebee;color:#c62828;border-radius:6px;border-left:4px solid #f44336}.upload-btn{padding:.875rem 2rem;background:#667eea;color:#fff;border:none;border-radius:6px;font-size:1rem;font-weight:600;cursor:pointer;transition:background .2s}.upload-btn:hover:not(:disabled){background:#5568d3}.upload-btn:disabled{background:#ccc;cursor:not-allowed}.template-list-container{width:100%}.template-list-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:2rem}.template-list-header h2{font-size:1.75rem;color:#333}.header-actions{display:flex;gap:1rem}.upload-toggle-button{padding:.5rem 1.5rem;background-color:#4caf50;color:#fff;border:none;border-radius:6px;cursor:pointer;font-size:.95rem;font-weight:600;transition:background-color .2s}.upload-toggle-button:hover{background-color:#45a049}.refresh-button{padding:.5rem 1.5rem;background-color:#667eea;color:#fff;border:none;border-radius:6px;cursor:pointer;font-size:.95rem;transition:background-color .2s}.refresh-button:hover{background-color:#5568d3}.template-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:1.5rem}.template-card{background:#fff;border-radius:8px;box-shadow:0 2px 8px #0000001a;padding:1.5rem;cursor:pointer;transition:transform .2s,box-shadow .2s}.template-card:hover{transform:translateY(-4px);box-shadow:0 4px 16px #00000026}.template-card.template-disabled{opacity:.6;cursor:not-allowed}.template-card.template-disabled:hover{transform:none;box-shadow:0 2px 8px #0000001a}.template-thumbnail{background:#fafafa;border-radius:6px;padding:0;margin-bottom:1rem;display:flex;align-items:center;justify-content:center;position:relative;overflow:hidden;min-height:180px}.template-badge{position:absolute;top:.5rem;right:.5rem;background-color:#4caf50;color:#fff;padding:.25rem .5rem;border-radius:4px;font-size:.7rem;font-weight:700}.template-badge-warning{position:absolute;top:.5rem;right:.5rem;background-color:#ff9800;color:#fff;padding:.25rem .5rem;border-radius:4px;font-size:.65rem;font-weight:700}.template-badges{position:absolute;top:8px;right:8px;display:flex;flex-direction:column;gap:6px;align-items:flex-end;z-index:10}.template-type-badge{padding:4px 10px;border-radius:4px;font-size:.75rem;font-weight:600;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);box-shadow:0 2px 4px #0000001a}.template-type-badge.page{background:#4caf50e6;color:#fff}.template-type-badge.story{background:#2196f3e6;color:#fff}.template-icon{width:80px;height:80px;color:#fff}.template-icon svg{width:100%;height:100%}.template-info h3{font-size:1.25rem;color:#333;margin-bottom:.5rem;text-transform:capitalize}.template-filename{font-size:.875rem;color:#666;font-family:Courier New,monospace}.template-actions{margin-top:1rem}.edit-button{width:100%;padding:.75rem;background-color:#667eea;color:#fff;border:none;border-radius:6px;cursor:pointer;font-size:1rem;font-weight:500;transition:background-color .2s}.edit-button:hover{background-color:#5568d3}.edit-button-disabled{width:100%;padding:.75rem;background-color:#ccc;color:#666;border:none;border-radius:6px;cursor:not-allowed;font-size:.9rem;font-weight:500}.loading,.empty-state,.error-message{text-align:center;padding:3rem;background:#fff;border-radius:8px;box-shadow:0 2px 8px #0000001a}.loading{font-size:1.125rem;color:#666}.empty-state h3,.error-message h3{font-size:1.5rem;color:#333;margin-bottom:1rem}.empty-state p,.error-message p{color:#666;margin-bottom:1.5rem}.empty-state code{background:#f5f5f5;padding:.25rem .5rem;border-radius:4px;font-size:.875rem}.retry-button{padding:.75rem 2rem;background-color:#667eea;color:#fff;border:none;border-radius:6px;cursor:pointer;font-size:1rem;transition:background-color .2s}.retry-button:hover{background-color:#5568d3}.content-editor{display:flex;flex-direction:column;gap:1.5rem}.no-selection{text-align:center;padding:3rem 1rem;color:#999}.no-selection svg{width:64px;height:64px;margin:0 auto 1rem;opacity:.3}.no-selection p{font-size:.95rem;line-height:1.5}.element-info{background:#f8f9fa;padding:1rem;border-radius:6px}.element-info h4{font-size:1rem;color:#333;margin-bottom:.75rem}.info-grid{display:flex;flex-direction:column;gap:.5rem}.info-item{display:flex;justify-content:space-between;font-size:.875rem}.info-item .label{color:#666;font-weight:500}.info-item .value{color:#333;font-family:Courier New,monospace}.content-input-section{display:flex;flex-direction:column;gap:.5rem}.input-header{display:flex;justify-content:space-between;align-items:center}.input-header label{font-size:.95rem;font-weight:600;color:#333}.reset-button{padding:.4rem .75rem;background-color:#f5f5f5;color:#666;border:1px solid #ddd;border-radius:4px;cursor:pointer;font-size:.8rem;transition:all .2s}.reset-button:hover{background-color:#e8e8e8;color:#333}.content-textarea{width:100%;padding:.75rem;border:2px solid #e0e0e0;border-radius:6px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif;font-size:.95rem;line-height:1.6;resize:vertical;transition:border-color .2s}.content-textarea:focus{outline:none;border-color:#667eea}.character-count{font-size:.8rem;color:#999;text-align:right}.editor-tips{background:#e8f5e9;padding:1rem;border-radius:6px;border-left:4px solid #4caf50}.editor-tips h5{font-size:.9rem;color:#2e7d32;margin-bottom:.5rem}.editor-tips ul{margin:0;padding-left:1.25rem}.editor-tips li{font-size:.85rem;color:#2e7d32;margin-bottom:.25rem}.template-editor{width:100%}.editor-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:2rem;padding-bottom:1rem;border-bottom:2px solid #e0e0e0}.back-button{padding:.5rem 1rem;background-color:#f5f5f5;color:#333;border:1px solid #ddd;border-radius:6px;cursor:pointer;font-size:.95rem;transition:background-color .2s}.back-button:hover{background-color:#e8e8e8}.editor-header h2{font-size:1.75rem;color:#333;text-transform:capitalize}.save-indicator{padding:.5rem 1rem;background-color:#e8f5e9;color:#2e7d32;border-radius:6px;font-size:.875rem;font-weight:500}.editor-content{display:grid;grid-template-columns:1fr 400px;gap:2rem;align-items:start}.canvas-section,.editor-section{background:#fff;border-radius:8px;box-shadow:0 2px 8px #0000001a;padding:1.5rem}.canvas-section h3,.editor-section h3{font-size:1.25rem;color:#333;margin-bottom:1.5rem;padding-bottom:.75rem;border-bottom:2px solid #f0f0f0}.loading-state,.error-state{text-align:center;padding:3rem;background:#fff;border-radius:8px;box-shadow:0 2px 8px #0000001a}.error-state h3{font-size:1.5rem;color:#d32f2f;margin-bottom:1rem}.error-state p{color:#666;margin-bottom:1.5rem}.error-state button{padding:.75rem 2rem;background-color:#667eea;color:#fff;border:none;border-radius:6px;cursor:pointer;font-size:1rem}@media (max-width: 1024px){.editor-content{grid-template-columns:1fr}}.image-converter{max-width:1200px;margin:0 auto;padding:2rem;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,sans-serif;color:#1f2937}.converter-header{text-align:center;margin-bottom:3rem}.converter-header h1{font-size:2.5rem;font-weight:700;color:#1e40af;margin:0 0 .5rem}.subtitle{font-size:1.1rem;color:#6b7280;margin:0}.progress-steps{display:flex;align-items:center;justify-content:center;margin-bottom:3rem;padding:2rem 0}.step{display:flex;flex-direction:column;align-items:center;gap:.5rem}.step-number{width:48px;height:48px;border-radius:50%;background:#e5e7eb;color:#9ca3af;display:flex;align-items:center;justify-content:center;font-weight:600;font-size:1.25rem;transition:all .3s}.step.active .step-number{background:#2563eb;color:#fff}.step.completed .step-number{background:#10b981;color:#fff}.step-label{font-size:.875rem;font-weight:500;color:#9ca3af}.step.active .step-label{color:#2563eb}.step.completed .step-label{color:#10b981}.step-divider{width:80px;height:2px;background:#e5e7eb;margin:0 1rem;margin-bottom:30px}.alert{padding:1rem 1.5rem;border-radius:8px;margin-bottom:2rem;display:flex;align-items:center;gap:.75rem}.alert-error{background:#fef2f2;border:1px solid #fecaca;color:#991b1b}.alert-icon{font-size:1.25rem}.upload-section{max-width:600px;margin:0 auto}.upload-area{position:relative;margin-bottom:2rem}#file-input{display:none}.upload-label{display:block;padding:4rem 2rem;border:3px dashed #cbd5e1;border-radius:12px;text-align:center;cursor:pointer;transition:all .3s;background:#f8fafc}.upload-label:hover{border-color:#2563eb;background:#eff6ff}.upload-icon{font-size:4rem;margin-bottom:1rem}.upload-text{font-size:1.125rem;margin-bottom:.5rem;color:#1f2937}.upload-hint{font-size:.875rem;color:#6b7280}.loading{text-align:center;padding:2rem}.spinner{width:48px;height:48px;margin:0 auto 1rem;border:4px solid #e5e7eb;border-top-color:#2563eb;border-radius:50%;animation:spin 1s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}.btn-spinner{width:16px;height:16px;border:2px solid white;border-top-color:transparent;border-radius:50%;animation:spin .6s linear infinite;display:inline-block;margin-right:.5rem}.preview-card{background:#fff;border-radius:12px;padding:1.5rem;box-shadow:0 4px 6px -1px #0000001a}.preview-image{width:100%;max-height:400px;object-fit:contain;border-radius:8px;margin-bottom:1rem}.preview-info{display:flex;justify-content:space-between;align-items:center;padding-top:1rem;border-top:1px solid #e5e7eb}.preview-info strong{color:#1f2937}.preview-info span{color:#6b7280;font-size:.875rem}.config-section{display:grid;grid-template-columns:1fr 1fr;gap:2rem;margin-top:2rem}@media (max-width: 968px){.config-section{grid-template-columns:1fr}}.image-preview-card{background:#fff;border-radius:12px;padding:1.5rem;box-shadow:0 4px 6px -1px #0000001a;height:fit-content}.preview-thumbnail{width:100%;max-height:300px;object-fit:cover;border-radius:8px;margin-bottom:1.5rem}.image-info h3{font-size:1.125rem;font-weight:600;margin:0 0 1rem;color:#1f2937}.info-grid{display:grid;gap:1rem}.info-item{display:flex;justify-content:space-between;align-items:start;padding:.75rem 0;border-bottom:1px solid #f3f4f6}.info-item:last-child{border-bottom:none}.info-label{font-weight:500;color:#6b7280;font-size:.875rem}.info-value{font-weight:500;color:#1f2937;text-align:right}.settings-card{background:#fff;border-radius:12px;padding:1.5rem;box-shadow:0 4px 6px -1px #0000001a;height:fit-content}.settings-card h3{font-size:1.125rem;font-weight:600;margin:0 0 1.5rem;color:#1f2937}.form-group{margin-bottom:1.5rem}.form-group label{display:block;font-weight:600;color:#374151;margin-bottom:.5rem;font-size:.875rem}.required{color:#ef4444;margin-left:.25rem}.form-select{width:100%;padding:.75rem 1rem;border:2px solid #e5e7eb;border-radius:8px;font-size:1rem;background:#fff;color:#1f2937;cursor:pointer;transition:all .2s}.form-select:hover{border-color:#cbd5e1}.form-select:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px #2563eb1a}.form-select:disabled{opacity:.5;cursor:not-allowed}.form-hint{margin:.5rem 0 0;font-size:.875rem;color:#6b7280;line-height:1.5}.badge{display:inline-block;padding:.25rem .75rem;border-radius:9999px;font-size:.875rem;font-weight:500}.badge-rgb{background:#dbeafe;color:#1e40af}.badge-cmyk{background:#fce7f3;color:#9f1239}.badge-success{background:#d1fae5;color:#065f46}.badge-warning{background:#fef3c7;color:#92400e}.warnings{margin-top:1rem;padding-top:1rem;border-top:1px solid #f3f4f6}.warning-item{background:#fffbeb;border-left:4px solid #f59e0b;padding:.75rem 1rem;margin-bottom:.5rem;color:#92400e;font-size:.875rem;line-height:1.5;border-radius:4px}.button-group{display:flex;gap:1rem;margin-top:2rem}.btn{padding:.75rem 1.5rem;border:none;border-radius:8px;font-size:1rem;font-weight:600;cursor:pointer;transition:all .2s;display:inline-flex;align-items:center;justify-content:center;gap:.5rem}.btn:disabled{opacity:.5;cursor:not-allowed}.btn-primary{background:#2563eb;color:#fff;flex:1}.btn-primary:hover:not(:disabled){background:#1d4ed8;transform:translateY(-1px);box-shadow:0 4px 6px -1px #2563eb4d}.btn-secondary{background:#e5e7eb;color:#374151}.btn-secondary:hover:not(:disabled){background:#d1d5db}.btn-large{padding:1rem 2rem;font-size:1.125rem}.result-section{max-width:800px;margin:0 auto}.success-card{background:linear-gradient(135deg,#d1fae5,#a7f3d0);border-radius:12px;padding:3rem 2rem;text-align:center;margin-bottom:2rem}.success-icon{font-size:4rem;margin-bottom:1rem}.success-card h2{font-size:2rem;font-weight:700;color:#065f46;margin:0 0 .5rem}.success-card p{font-size:1.125rem;color:#047857;margin:0}.result-details{background:#fff;border-radius:12px;padding:2rem;box-shadow:0 4px 6px -1px #0000001a;margin-bottom:2rem}.result-details h3{font-size:1.25rem;font-weight:600;margin:0 0 1.5rem;color:#1f2937}.result-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:1rem;margin-bottom:2rem}@media (max-width: 640px){.result-grid{grid-template-columns:1fr}}.result-item{display:flex;flex-direction:column;gap:.25rem}.result-label{font-size:.875rem;color:#6b7280;font-weight:500}.result-value{font-size:1rem;color:#1f2937;font-weight:600}.info-box{background:#eff6ff;border:1px solid #bfdbfe;border-radius:12px;padding:1.5rem}.info-box h4{font-size:1rem;font-weight:600;color:#1e40af;margin:0 0 1rem}.info-box ul{margin:0;padding-left:1.5rem;color:#1e40af}.info-box li{margin-bottom:.5rem;line-height:1.6}.technical-note{margin-top:3rem;padding-top:2rem;border-top:2px solid #e5e7eb}.technical-note details{background:#f9fafb;border-radius:8px;padding:1rem}.technical-note summary{cursor:pointer;font-weight:600;color:#374151;padding:.5rem;-webkit-user-select:none;user-select:none}.technical-note summary:hover{color:#1f2937}.note-content{padding:1rem;color:#4b5563;line-height:1.6}.note-content p{margin:0 0 1rem}.note-content ul{margin:0 0 1rem;padding-left:1.5rem}.note-content li{margin-bottom:.5rem}.note-content strong{color:#1f2937}@media (max-width: 640px){.image-converter{padding:1rem}.converter-header h1{font-size:2rem}.progress-steps{padding:1rem 0}.step-number{width:36px;height:36px;font-size:1rem}.step-divider{width:40px;margin:0 .5rem;margin-bottom:22px}.step-label{font-size:.75rem}.button-group{flex-direction:column}.btn{width:100%}}.app{min-height:100vh;display:flex;flex-direction:column}.app-header{background:linear-gradient(135deg,#667eea,#764ba2);color:#fff;padding:2rem;box-shadow:0 2px 10px #0000001a}.app-header h1{font-size:2rem;margin-bottom:.5rem}.app-header p{font-size:1rem;opacity:.9;margin-bottom:1.5rem}.app-nav{display:flex;gap:1rem;margin-top:1rem}.nav-link{color:#fff;text-decoration:none;padding:.5rem 1.25rem;border-radius:6px;font-weight:500;transition:all .2s ease;background:#ffffff1a;border:1px solid rgba(255,255,255,.2)}.nav-link:hover{background:#fff3;transform:translateY(-1px)}.nav-link.active{background:#ffffff40;border-color:#fff6;box-shadow:0 2px 8px #0000001a}.app-main{flex:1;padding:2rem;max-width:1400px;width:100%;margin:0 auto}*{margin:0;padding:0;box-sizing:border-box}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:#f5f5f5}code{font-family:source-code-pro,Menlo,Monaco,Consolas,Courier New,monospace}#root{min-height:100vh}
