/* svg-to-gif.css – External CSS for SVG to GIF Converter */

/* ========== Security Alert ========== */
.security-alert {
  text-align: center;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background-color: #e6fffa;
  border: 1px solid #4fd1c5;
  border-radius: 0.5rem;
  font-weight: 600;
  color: #38a169;
}

/* ========== Mode Buttons & Icons ========== */
.mode-btn__icon {
  width: 18px;
  height: 18px;
  margin-right: 8px;
}

/* ========== Upload Button ========== */
.upload-btn {
  padding: 0.75rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  margin: 0 auto;
}

.upload-btn__icon {
  width: 18px;
  height: 18px;
}

/* ========== Preview Header ========== */
.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.preview-title {
  font-size: 1.1rem;
  color: #2d3748;
  margin: 0;
}

.animation-indicator {
  margin-left: 10px;
  font-size: 0.9rem;
  color: #4299e1;
  background: #ebf8ff;
  padding: 2px 8px;
  border-radius: 12px;
}

.animation-indicator__icon {
  width: 14px;
  height: 14px;
  margin-right: 4px;
  vertical-align: middle;
}

.clear-btn {
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  background: #f7fafc;
  color: #e53e3e;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

/* ========== Image Grid ========== */
.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 1rem;
  max-height: 300px;
  overflow-y: auto;
  padding: 0.5rem;
}

/* ========== Frame Order Controls ========== */
.frame-order-controls {
  margin-top: 1rem;
  padding: 1rem;
  background: #f8fafc;
  border-radius: 8px;
}

.frame-order-title {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.frame-order-desc {
  margin: 0 0 0.5rem 0;
  color: #718096;
  font-size: 0.9rem;
}

.sortable-frames {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  min-height: 60px;
  padding: 0.5rem;
  background: white;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

/* ========== Settings Headers ========== */
.settings-header {
  margin-top: 0;
  margin-bottom: 1rem;
  color: #2d3748;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.settings-header__icon {
  width: 20px;
  height: 20px;
}

/* ========== Resize Mode Options ========== */
.resize-mode-options {
  display: flex;
  gap: 1rem;
}

.resize-mode-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.resize-mode-radio {
  width: 16px;
  height: 16px;
}

/* ========== Current Size Info ========== */
.current-size-info {
  color: #4a5568;
  font-style: italic;
}

/* ========== Loop Animation Controls ========== */
.loop-animation-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.loop-animation-checkbox {
  width: 18px;
  height: 18px;
}

/* ========== Action Section & Convert Button ========== */
.action-section {
  text-align: center;
  margin: 1.5rem 0;
}

.convert-btn {
  padding: 1rem 3rem;
  font-size: 1.1rem;
  font-weight: 600;
  background: linear-gradient(135deg, #4299e1, #2b6cb0);
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 6px 16px rgba(66, 153, 225, 0.4);
  position: relative;
  overflow: hidden;
}

.convert-btn__icon {
  width: 22px;
  height: 22px;
}

/* ========== Progress Section ========== */
.progress-section {
  margin: 1.5rem 0;
}

.progress-card {
  padding: 1.5rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.07);
  border: 2px solid #e2e8f0;
}

.progress-card-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e2e8f0;
  border-top: 3px solid #4299e1;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.progress-info {
  flex: 1;
}

.progress-title {
  font-size: 1rem;
  margin: 0 0 0.5rem 0;
  color: #2d3748;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #4299e1, #2b6cb0);
  transition: width 0.3s ease;
  border-radius: 4px;
}

.progress-text {
  margin: 0.5rem 0 0 0;
  color: #718096;
  font-size: 0.85rem;
}

/* ========== Results Section ========== */
.results-section {
  margin: 1.5rem 0;
}

.results-card {
  padding: 1.5rem;
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.07);
  border: 2px solid #86efac;
}

.results-card-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.results-icon-text {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.results-icon {
  width: 48px;
  height: 48px;
  color: #22c55e;
}

.results-title {
  font-size: 1.2rem;
  margin: 0 0 0.25rem 0;
  color: #166534;
}

.results-subtitle {
  margin: 0;
  color: #15803d;
  font-size: 0.95rem;
}

.download-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Base download button styles (overridden by specific variants below) */
.download-btn {
  padding: 0.85rem 2.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.download-btn__icon {
  width: 20px;
  height: 20px;
}

.download-btn--single {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
}

.download-btn--zip {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.download-btn--individual {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
}

/* Feature Grid & Cards */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.feature-card {
  padding: 20px;
  border-radius: 10px;
}

.feature-card--blue {
  background: #f8f9fa;
  border-left: 4px solid #4a7bff;
}

.feature-card--green {
  background: #f8f9fa;
  border-left: 4px solid #10b981;
}

/* FAQ Items */
.faq-item {
  margin-bottom: 20px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 20px;
}

.faq-question {
  font-weight: 600;
  color: #2d3748;
  margin-bottom: 8px;
}

.faq-answer {
  color: #4a5568;
}

/* NoScript Warning */
.noscript-warning {
  border: 2px solid #dc3545;
  padding: 20px;
  margin: 20px 0;
}

/* ========== Keyframes ========== */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ========== Modern Button Effects (shared) ========== */
.modern-button {
  position: relative;
  overflow: hidden;
}

.modern-button::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.modern-button:hover::before {
  width: 300px;
  height: 300px;
}

.modern-button:active {
  transform: translateY(0);
}

/* Upload button hover */
.upload-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

/* Convert button hover */
.convert-btn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 24px rgba(66, 153, 225, 0.5);
}

/* Download button hovers */
.download-btn:hover {
  transform: translateY(-2px);
}
#downloadBtn:hover {
  box-shadow: 0 6px 20px rgba(34, 197, 94, 0.5);
}
#downloadZipBtn:hover {
  box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5);
  background: linear-gradient(135deg, #7c3aed, #6d28d9);
}
#downloadIndividualBtn:hover {
  box-shadow: 0 6px 20px rgba(34, 197, 94, 0.5);
}

/* Image grid scrollbar */
.image-grid::-webkit-scrollbar { width: 8px; }
.image-grid::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 4px; }
.image-grid::-webkit-scrollbar-thumb { background: #cbd5e0; border-radius: 4px; }
.image-grid::-webkit-scrollbar-thumb:hover { background: #a0aec0; }

/* Clear button hover */
.clear-btn:hover {
  background: #fee2e2;
  border-color: #fca5a5;
}

/* Sortable frame transitions (used in JS dynamic styling) */
.sortable-frame {
  transition: all 0.3s;
}
.sortable-frame:hover {
  border-color: #4299e1 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(66, 153, 225, 0.2);
}
.sortable-frame.dragging { opacity: 0.5; }
.sortable-frame.over {
  border-color: #10b981 !important;
  transform: scale(1.05);
}