/* ===================================
   Tool: gif-maker
   =================================== */


/* Upload Area */
.upload-area {
  background: var(--bg-card);
  border: 3px dashed var(--border-color);
  border-radius: var(--radius-xl);
  padding: var(--space-3xl) var(--space-xl);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-normal);
  margin-bottom: var(--space-xl);
}
.upload-area:hover, .upload-area.dragover {
  border-color: var(--accent);
  background: var(--bg-secondary);
}
  .upload-icon { font-size: 3.5rem; display: block; margin-bottom: var(--space-md); }
  .upload-title { font-size: 1.25rem; font-weight: 600; margin-bottom: var(--space-sm); }
  .upload-hint { color: var(--text-muted); margin-bottom: var(--space-md); }
  .upload-formats { display: flex; gap: var(--space-sm); justify-content: center; flex-wrap: wrap; }
  .upload-input { display: none; }
  .format-badge {
  background: var(--bg-tertiary);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  }

  /* Settings */
  .gif-settings {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  margin-bottom: var(--space-xl);
  box-shadow: var(--shadow-sm);
  }
  .settings-title { font-size: 1.1rem; font-weight: 600; margin-bottom: var(--space-lg); }
  .gif-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-lg);
  }
  .setting-group {
  background: var(--bg-secondary);
  padding: var(--space-md);
  border-radius: var(--radius-lg);
  }
  .setting-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  margin-bottom: var(--space-sm);
  font-size: 0.9rem;
  }
  .setting-value {
  color: var(--accent);
  font-weight: 700;
  }
  .setting-slider {
  width: 100%;
  margin-bottom: var(--space-sm);
  }
  .setting-select, .setting-input {
  width: 100%;
  padding: var(--space-sm) var(--space-md);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  background: var(--bg-card);
  }
  .setting-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: var(--space-sm);
  }

  /* Image List */
  .gif-hint {
  text-align: center;
  padding: var(--space-md);
  color: var(--text-secondary);
  font-size: 0.9rem;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-md);
  }
  .gif-image-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: var(--space-md);
  min-height: 150px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
  }
  .gif-image-item {
  position: relative;
  aspect-ratio: 1;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: grab;
  transition: all var(--transition-fast);
  border: 2px solid transparent;
  }
  .gif-image-item:hover { border-color: var(--accent); }
  .gif-image-item:active { cursor: grabbing; }
  .gif-image-item.dragging { opacity: 0.5; transform: scale(0.95); }
  .gif-image-item .preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  }
  .gif-image-item .order-badge {
  position: absolute;
  top: var(--space-xs);
  left: var(--space-xs);
  background: var(--accent);
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  }
  .gif-image-item .remove-btn {
  position: absolute;
  top: var(--space-xs);
  right: var(--space-xs);
  background: var(--error, #e53935);
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  opacity: 0;
  transition: opacity var(--transition-fast);
  }
  .gif-image-item:hover .remove-btn { opacity: 1; }
  .gif-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-xl);
  color: var(--text-muted);
  }

  /* Action Bar */
  .action-bar {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--space-xl);
  }

  /* Progress */
  .progress-container {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
  display: none;
  }
  .progress-container.active { display: block; }
  .progress-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-sm);
  font-size: 0.9rem;
  }
  .progress-bar {
  height: 8px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-full);
  overflow: hidden;
  }
  .progress-fill {
  height: 100%;
  background: var(--accent);
  transition: width 0.2s ease;
  }

  /* Preview */
  .gif-preview-container {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  text-align: center;
  display: none;
  }
  .gif-preview-container.active { display: block; }
  .gif-preview-title {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: var(--space-lg);
  }
  .gif-preview-image {
  max-width: 100%;
  max-height: 400px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  margin-bottom: var(--space-md);
  }
  .gif-preview-info {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: var(--space-lg);
  }

  /* Toast styles inherited from main style.css */

  @media (max-width: 640px) {
  .gif-settings-grid { grid-template-columns: 1fr; }
  .gif-image-list { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); }
  }


