/* Layout resets */
:root {
  --radius-small: 10px;
  --radius-medium: 16px;
  --radius-large: 24px;
  --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.page-hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
  margin-bottom: 48px;
  align-items: center;
}

.page-hero .eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted-text);
  font-weight: 600;
}

.page-hero .lead {
  font-size: 22.4px;
  color: var(--muted-text);
  margin-bottom: 16px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-left: auto;
}

.hero-illustration {
  display: grid;
  gap: 16px;
}

.hero-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  padding: 24px;
  box-shadow: var(--shadow-soft, 0 20px 35px rgba(0, 0, 0, 0.05));
}

.hero-card i {
  font-size: 32px;
  color: var(--link);
  margin-bottom: 8px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.stat-card {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  padding: 24px;
  background: var(--card-bg);
}

.stat-label {
  text-transform: uppercase;
  font-size: 16px;
  color: var(--muted-text);
  letter-spacing: 0.08em;
}

.stat-value {
  font-size: 40px;
  font-weight: 700;
  margin: 4px 0;
  color: var(--heading-color);
}

.tool-grid .section-header {
  text-align: center;
  margin-bottom: 32px;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.tool-card {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
  background: var(--card-bg);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.tool-card:hover,
.tool-card:focus {
  transform: translateY(-4px);
  border-color: var(--link);
  box-shadow: 0 12px 32px rgba(102, 126, 234, 0.2);
}

.tool-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--link);
  background: rgba(102, 126, 234, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

/* Color variations for tool cards */
.tool-card-0 .tool-icon {
  background: rgba(102, 126, 234, 0.12);
  color: #667eea;
}

.tool-card-1 .tool-icon {
  background: rgba(237, 100, 166, 0.12);
  color: #ed64a6;
}

.tool-card-2 .tool-icon {
  background: rgba(72, 187, 120, 0.12);
  color: #48bb78;
}

.tool-card-3 .tool-icon {
  background: rgba(246, 173, 85, 0.12);
  color: #f6ad55;
}

.tool-card-4 .tool-icon {
  background: rgba(129, 140, 248, 0.12);
  color: #818cf8;
}

.tool-card-5 .tool-icon {
  background: rgba(251, 146, 60, 0.12);
  color: #fb923c;
}

.tool-card:hover .tool-icon {
  color: white;
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.tool-card-0:hover .tool-icon {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.tool-card-1:hover .tool-icon {
  background: linear-gradient(135deg, #ed64a6 0%, #f093fb 100%);
}

.tool-card-2:hover .tool-icon {
  background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
}

.tool-card-3:hover .tool-icon {
  background: linear-gradient(135deg, #f6ad55 0%, #ed8936 100%);
}

.tool-card-4:hover .tool-icon {
  background: linear-gradient(135deg, #818cf8 0%, #6366f1 100%);
}

.tool-card-5:hover .tool-icon {
  background: linear-gradient(135deg, #fb923c 0%, #f97316 100%);
}

.tool-card h3 {
  margin: 0;
  font-size: 18.4px;
  font-weight: 600;
  color: var(--text-color);
  line-height: 1.4;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
}

.tool-card:hover h3 {
  color: var(--link);
}

.tool-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.conversion-prefill {
  margin-bottom: 16px;
  border-left: 4px solid var(--link);
  background: rgba(0, 123, 255, 0.05);
}

.conversion-prefill p {
  margin: 0;
  font-size: 17.6px;
}

.tool-card-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.tool-card-header i {
  font-size: 32px;
  color: var(--link);
}

.tool-card-features {
  list-style: none;
  margin: 0;
  padding: 0;
  color: var(--muted-text);
}

.tool-card-features li {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 4.8px;
  font-size: 17.6px;
}

.tool-card-actions {
  margin-top: auto;
}

.tool-workbench {
  margin-bottom: 48px;
}

.tool-stepper {
  margin-bottom: 40px;
  position: relative;
}

.stepper-wrapper {
  display: flex;
  justify-content: center;
  padding: 24px 0;
}

.stepper-track {
  display: flex;
  align-items: center;
  gap: 0;
  position: relative;
  max-width: 900px;
  width: 100%;
}

.stepper-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14.4px;
  background: var(--card-bg, #ffffff);
  border: 2px solid var(--border-color, #e5e7eb);
  border-radius: var(--radius-medium, 16px);
  padding: 20px 16px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  z-index: 1;
  flex: 1;
  min-width: 140px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

[data-theme='dark'] .stepper-step {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.stepper-step:focus-visible {
  outline: 2px solid #667eea;
  outline-offset: 4px;
  border-radius: 8px;
}

.step-indicator {
  position: relative;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--input-bg, #e5e7eb);
  border: 4px solid var(--card-bg, #ffffff);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme='dark'] .step-indicator {
  background: linear-gradient(
    135deg,
    rgba(147, 197, 253, 0.3) 0%,
    rgba(96, 165, 250, 0.3) 100%
  );
  border: 4px solid rgba(191, 219, 254, 0.5);
  box-shadow:
    0 2px 12px rgba(0, 0, 0, 0.5),
    0 0 12px rgba(147, 197, 253, 0.2),
    inset 0 0 20px rgba(147, 197, 253, 0.1);
}

.step-number {
  font-size: 21.6px;
  font-weight: 800;
  color: var(--heading-color, #111827);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: absolute;
  z-index: 10;
  text-shadow: none;
}

[data-theme='dark'] .stepper-step:not(.is-active) .step-number {
  color: #dbeafe;
  text-shadow:
    0 0 16px rgba(147, 197, 253, 0.9),
    0 0 24px rgba(96, 165, 250, 0.6),
    0 2px 4px rgba(0, 0, 0, 0.6);
  font-weight: 900;
}

.step-checkmark {
  position: absolute;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  color: #ffffff;
}

.step-label {
  font-size: 17.6px;
  font-weight: 700;
  color: var(--heading-color, #000000) !important;
  text-align: center;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  z-index: 10;
  line-height: 1.5;
  text-shadow: none;
  opacity: 1 !important;
  visibility: visible !important;
  display: block !important;
}

[data-theme='dark']
  .stepper-step:not(.is-active):not(.is-complete)
  .step-label {
  color: var(--text-color, #ffffff) !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
  opacity: 1 !important;
  font-weight: 800;
}

.step-line {
  flex: 1;
  height: 4px;
  background: var(--border-color, #e5e7eb);
  position: relative;
  margin: 0;
  border-radius: 2px;
  overflow: hidden;
  max-width: 180px;
  align-self: stretch;
  margin-top: calc(32px + 20px);
}

.step-line-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
  border-radius: 2px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Active step */
.stepper-step.is-active {
  border-color: var(--link, #667eea);
  background: var(--card-bg, #ffffff);
  box-shadow:
    0 0 0 3px rgba(102, 126, 234, 0.15),
    0 8px 24px rgba(102, 126, 234, 0.2);
  transform: translateY(-2px);
}

[data-theme='dark'] .stepper-step.is-active {
  border-color: var(--link, #a78bfa);
  box-shadow:
    0 0 0 3px rgba(167, 139, 250, 0.4),
    0 0 24px rgba(167, 139, 250, 0.3),
    0 0 40px rgba(139, 92, 246, 0.2),
    0 8px 32px rgba(139, 92, 246, 0.5);
  transform: translateY(-3px);
}

.stepper-step.is-active .step-indicator {
  background: var(
    --gradient-primary,
    linear-gradient(135deg, #667eea 0%, #764ba2 100%)
  );
  border-color: var(--card-bg, #ffffff);
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.9),
    0 0 0 8px rgba(102, 126, 234, 0.25),
    0 6px 24px rgba(102, 126, 234, 0.35);
  transform: scale(1.05);
  animation: stepPulse 2s ease-in-out infinite;
}

[data-theme='dark'] .stepper-step.is-active .step-indicator {
  background: linear-gradient(135deg, #a78bfa 0%, #c4b5fd 100%);
  border: 4px solid rgba(255, 255, 255, 0.9);
  box-shadow:
    0 0 0 2px rgba(167, 139, 250, 0.5),
    0 0 0 6px rgba(139, 92, 246, 0.4),
    0 0 24px rgba(167, 139, 250, 0.6),
    0 0 40px rgba(139, 92, 246, 0.4),
    0 8px 32px rgba(139, 92, 246, 0.7),
    inset 0 0 20px rgba(255, 255, 255, 0.1);
  transform: scale(1.08);
}

.stepper-step.is-active .step-number {
  color: #ffffff;
  opacity: 1;
  font-size: 28px;
}

[data-theme='dark'] .stepper-step.is-active .step-number {
  color: #ffffff;
  text-shadow:
    0 0 16px rgba(255, 255, 255, 0.8),
    0 0 24px rgba(255, 255, 255, 0.5),
    0 2px 4px rgba(0, 0, 0, 0.5);
  font-weight: 900;
}

.stepper-step.is-active .step-label {
  color: var(--link, #667eea) !important;
  font-weight: 800;
  font-size: 18.4px;
  letter-spacing: 1.2px;
  text-shadow: 0 1px 2px rgba(102, 126, 234, 0.2);
  opacity: 1 !important;
}

[data-theme='dark'] .stepper-step.is-active .step-label {
  color: #e9d5ff !important;
  text-shadow:
    0 0 16px rgba(233, 213, 255, 0.8),
    0 0 24px rgba(167, 139, 250, 0.6),
    0 0 32px rgba(139, 92, 246, 0.4),
    0 2px 4px rgba(0, 0, 0, 0.5);
  opacity: 1 !important;
}

/* Completed step */
.stepper-step.is-complete {
  border-color: rgba(102, 126, 234, 0.2);
}

[data-theme='dark'] .stepper-step.is-complete {
  border-color: rgba(139, 92, 246, 0.3);
}

.stepper-step.is-complete .step-indicator {
  background: var(
    --gradient-primary,
    linear-gradient(135deg, #667eea 0%, #764ba2 100%)
  );
  border-color: var(--card-bg, #ffffff);
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

[data-theme='dark'] .stepper-step.is-complete .step-indicator {
  background: linear-gradient(135deg, #a78bfa 0%, #c4b5fd 100%);
  border: 4px solid rgba(255, 255, 255, 0.7);
  box-shadow:
    0 4px 16px rgba(167, 139, 250, 0.5),
    0 0 24px rgba(139, 92, 246, 0.3),
    inset 0 0 20px rgba(255, 255, 255, 0.1);
}

.stepper-step.is-complete .step-number {
  opacity: 0;
  transform: scale(0);
}

.stepper-step.is-complete .step-checkmark {
  opacity: 1;
  transform: scale(1);
}

.stepper-step.is-complete .step-label {
  color: #667eea !important;
  font-weight: 700;
  font-size: 18px;
  opacity: 1 !important;
}

[data-theme='dark'] .stepper-step.is-complete .step-label {
  color: #d8b4fe !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  opacity: 1 !important;
}

/* Completed line */
.stepper-step.is-complete ~ .step-line .step-line-progress,
.stepper-step.is-active ~ .step-line .step-line-progress {
  width: 100%;
}

/* Hover states */
.stepper-step:not(.is-active):not(.is-complete):hover {
  border-color: var(--border-color, #d1d5db);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

[data-theme='dark'] .stepper-step:not(.is-active):not(.is-complete):hover {
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.stepper-step:not(.is-active):not(.is-complete):hover .step-indicator {
  background: #d1d5db;
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

[data-theme='dark'] .stepper-step:not(.is-active):not(.is-complete):hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(20, 20, 30, 1);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

[data-theme='dark']
  .stepper-step:not(.is-active):not(.is-complete):hover
  .step-indicator {
  background: linear-gradient(
    135deg,
    rgba(147, 197, 253, 0.5) 0%,
    rgba(96, 165, 250, 0.5) 100%
  );
  border-color: rgba(191, 219, 254, 0.8);
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.5),
    0 0 20px rgba(96, 165, 250, 0.5),
    0 0 32px rgba(147, 197, 253, 0.4),
    inset 0 0 24px rgba(147, 197, 253, 0.2);
  transform: scale(1.05);
}

.stepper-step:not(.is-active):not(.is-complete):hover .step-label {
  color: var(--heading-color, #000000) !important;
  font-weight: 800;
  opacity: 1 !important;
}

[data-theme='dark']
  .stepper-step:not(.is-active):not(.is-complete):hover
  .step-label {
  color: var(--text-color, #ffffff) !important;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  opacity: 1 !important;
}

@media (max-width: 1024px) {
  .stepper-wrapper {
    padding: 16px 0;
  }

  .stepper-track {
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 12px;
  }

  .stepper-step {
    flex: 1 1 0;
    min-width: 0;
  }

  .step-line {
    display: none;
  }
}

@media (max-width: 768px) {
  .stepper-track {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .stepper-step {
    flex: 1 1 auto;
    width: 100%;
  }
}

@keyframes stepPulse {
  0%,
  100% {
    box-shadow:
      0 0 0 4px rgba(255, 255, 255, 0.9),
      0 0 0 8px rgba(102, 126, 234, 0.25),
      0 6px 24px rgba(102, 126, 234, 0.35);
  }
  50% {
    box-shadow:
      0 0 0 6px rgba(255, 255, 255, 0.95),
      0 0 0 10px rgba(102, 126, 234, 0.35),
      0 8px 28px rgba(102, 126, 234, 0.45);
  }
}

[data-theme='dark'] .stepper-step.is-active .step-indicator {
  animation: stepPulseDark 2s ease-in-out infinite;
}

@keyframes stepPulseDark {
  0%,
  100% {
    box-shadow:
      0 0 0 2px rgba(167, 139, 250, 0.5),
      0 0 0 6px rgba(139, 92, 246, 0.4),
      0 0 24px rgba(167, 139, 250, 0.6),
      0 0 40px rgba(139, 92, 246, 0.4),
      0 8px 32px rgba(139, 92, 246, 0.7),
      inset 0 0 20px rgba(255, 255, 255, 0.1);
  }
  50% {
    box-shadow:
      0 0 0 3px rgba(167, 139, 250, 0.7),
      0 0 0 8px rgba(139, 92, 246, 0.6),
      0 0 32px rgba(167, 139, 250, 0.8),
      0 0 50px rgba(139, 92, 246, 0.5),
      0 10px 40px rgba(139, 92, 246, 0.9),
      inset 0 0 24px rgba(255, 255, 255, 0.15);
  }
}

.step-panel {
  display: none;
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-panel.is-active {
  display: block;
  opacity: 1;
  transform: translateY(0);
  animation: stepPanelSlideIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes stepPanelSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.step-panel + .step-panel {
  margin-top: 32px;
}

.options-panel,
.results-panel {
  border-radius: var(--radius-medium);
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 24px;
}

.dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-large);
  padding: 48px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: var(--card-bg);
  transition:
    border-color 0.3s ease,
    background 0.3s ease,
    box-shadow 0.3s ease,
    transform 0.3s ease;
  cursor: pointer;
}

.dropzone::before {
  content: '';
  position: absolute;
  inset: 0;
  left: -100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(64, 140, 255, 0.12),
    transparent
  );
  opacity: 0;
  transition:
    left 0.6s ease,
    opacity 0.3s ease;
}

.dropzone:hover {
  border-color: var(--link);
  background: rgba(64, 140, 255, 0.05);
}

.dropzone:hover::before {
  opacity: 1;
  left: 100%;
}

.dropzone.is-hovered {
  border-color: var(--link);
  background: rgba(64, 140, 255, 0.08);
  transform: scale(1.01);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.12);
}

.dropzone.is-hovered::before {
  opacity: 1;
  left: 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

.dropzone-icon {
  font-size: 56px;
  color: var(--link);
  margin-bottom: 16px;
  animation: dropBounce 2.5s ease-in-out infinite;
}

@keyframes dropBounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.dropzone.is-hovered .dropzone-icon {
  animation: dropPulse 0.9s ease-in-out infinite;
}

@keyframes dropPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.12);
  }
}

.dropzone-text {
  font-size: 22.4px;
  font-weight: 600;
  color: var(--heading-color);
  margin-bottom: 5.6px;
}

.dropzone-hint {
  color: var(--muted-text);
  font-size: 16.8px;
  margin: 0;
}

.dropzone-sample {
  margin-top: 16px;
  text-align: center;
}

.dropzone-sample .button {
  font-size: 14.4px;
}

.dropzone-meta {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.dropzone-pill {
  display: inline-flex;
  align-items: center;
  gap: 6.4px;
  padding: 5.6px 14.4px;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: var(--input-bg);
  font-size: 15.2px;
  color: var(--muted-text);
}

.dropzone-pill i {
  color: var(--link);
  font-size: 13.6px;
}

.dropzone [data-file-input] {
  display: none;
}

.dropzone-loading {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 8px;
  z-index: 2;
  backdrop-filter: blur(2px);
}

.dropzone-loading .spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.file-queue .queue-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.queue-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.queue-placeholder {
  color: var(--muted-text);
  font-style: italic;
}

.queue-item {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  padding: 16px;
  background: var(--input-bg);
}

.queue-item--processing {
  border-color: var(--link);
}

.queue-item--done {
  border-color: #2ecc71;
}

.queue-item--error {
  border-color: #ff6b6b;
}

.queue-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.queue-status {
  margin-top: 12px;
  font-size: 16.8px;
  color: var(--muted-text);
}

.queue-progress {
  height: 4px;
  background: var(--border-color);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 8px;
}

.queue-progress-bar {
  display: block;
  height: 100%;
  width: 60%;
  background: var(--link);
  opacity: 0.4;
  transition: width 0.3s ease;
}

.queue-item--done .queue-progress-bar {
  width: 100%;
  opacity: 1;
}

.options-panel {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-group,
.form-check {
  margin-bottom: 16px;
}

.form-row.two-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
}

.range-control {
  display: flex;
  align-items: center;
  gap: 16px;
}

.range-control input[type='range'] {
  flex: 1;
}

.range-value {
  min-width: 48px;
  text-align: right;
  font-weight: 600;
}

.options-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.results-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  margin-bottom: 24px;
}

@media (max-width: 1024px) {
  .results-actions {
    justify-content: flex-start;
    gap: 9.6px;
  }

  .results-actions .button {
    padding: 24px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    line-height: 1;
  }

  .results-actions .button i {
    margin-right: 0;
    font-size: 16px;
    line-height: 1;
  }
}

@media (max-width: 768px) {
  .results-actions {
    justify-content: center;
    gap: 8px;
  }

  .results-actions .button {
    padding: 24px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    line-height: 1;
  }

  .results-actions .button i {
    margin-right: 0;
    font-size: 16px;
    line-height: 1;
  }
}

details.advanced-options {
  margin-top: 24px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  padding: 16px 20px;
  background: var(--card-bg);
}

details.advanced-options summary {
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

details.advanced-options summary::-webkit-details-marker {
  display: none;
}

details.advanced-options summary::before {
  content: '▸';
  font-size: 13.6px;
  transition: transform 0.2s ease;
}

details.advanced-options[open] summary::before {
  transform: rotate(90deg);
}

details.advanced-options .advanced-body {
  margin-top: 16px;
  display: grid;
  gap: 16px;
}

.compression-summary {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  padding: 16px 20px;
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-medium);
  background: rgba(0, 123, 255, 0.05);
  margin-bottom: 24px;
}

.compression-summary[hidden] {
  display: none;
}

.compression-summary .stat {
  min-width: 160px;
}

.compression-summary .stat-label {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 15.2px;
  color: var(--muted-text);
  margin-bottom: 5.6px;
}

.compression-summary .stat-value {
  font-size: 25.6px;
  font-weight: 700;
  margin: 0;
  color: var(--heading-color);
}

.compression-summary .stat-sub {
  margin: 3.2px 0 0;
  font-size: 16.8px;
  color: var(--muted-text);
}

.compression-card-stats {
  margin-top: 12px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.compression-card-stats div {
  min-width: 140px;
}

.compression-card-stats span {
  display: block;
}

.compression-card-stats .label {
  text-transform: uppercase;
  font-size: 14.4px;
  letter-spacing: 0.06em;
  color: var(--muted-text);
  margin-bottom: 3.2px;
}

.compression-card-stats .value {
  font-weight: 600;
  color: var(--heading-color);
}

.preview-strip {
  margin-top: 24px;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  background: var(--card-bg);
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 20px;
  min-height: 160px;
}

.preview-strip .preview-placeholder {
  color: var(--muted-text);
  margin: 0;
}

.preview-card {
  width: 140px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  overflow: hidden;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
  background: var(--card-bg);
  aspect-ratio: 4 / 3;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  flex: 0 0 auto;
}

.preview-card:hover {
  transform: translateY(-2px);
  border-color: var(--link);
}

.preview-card .preview-thumb {
  flex: 1;
  position: relative;
  overflow: hidden;
}

.preview-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition:
    transform 0.4s ease,
    filter 0.3s ease;
}

.preview-watermark-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  display: none;
}

.preview-card .preview-label {
  margin: 0;
  padding: 6.4px 9.6px;
  font-size: 14.4px;
  color: var(--muted-text);
  background: rgba(0, 0, 0, 0.03);
  border-top: 1px solid var(--border-color);
}

.preview-card .preview-label span {
  font-weight: 600;
  margin-right: 4px;
}

.preview-modal[hidden] {
  display: none;
}

.preview-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.preview-modal-content {
  position: relative;
  background: #101010;
  border-radius: var(--radius-medium);
  max-width: 90vw;
  max-height: 90vh;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
  color: #fff;
  overflow: hidden;
}

.preview-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 13.6px 19.2px;
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.preview-modal-title {
  font-weight: 600;
  margin: 0;
}

.preview-modal-body {
  max-width: 80vw;
  max-height: 80vh;
  padding: 16px;
  background: #000;
}

.preview-modal-stage {
  position: relative;
  width: 100%;
  max-height: 80vh;
}

.preview-modal-stage img {
  width: 100%;
  height: auto;
  max-height: 80vh;
  display: block;
  margin: 0 auto;
}

.preview-modal-stage .preview-watermark-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  display: none;
}

.preview-modal-close {
  border: none;
  background: transparent;
  font-size: 22.4px;
  cursor: pointer;
  line-height: 1;
  color: #fff;
  padding: 3.2px;
}

.preview-modal-close:hover,
.preview-modal-close:focus {
  color: var(--link);
}

.quick-rotate-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.quick-rotate-buttons .button-pill {
  font-size: 16px;
  padding: 6.4px 12.8px;
}

.total-progress {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.progress-track {
  height: 6px;
  background: var(--border-color);
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: var(--link);
  transition: width 0.3s ease;
}

.results-grid {
  margin-top: 32px;
  overflow-x: auto;
}

.results-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.results-table thead th {
  text-align: left;
  padding: 12px 16px;
  font-size: 14.4px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-text);
  border-bottom: 1px solid var(--border-color);
}

.results-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
  transition: background 0.2s ease;
}

.results-table tbody tr:last-child td {
  border-bottom: none;
}

.results-preview {
  width: 140px;
}

.result-thumb {
  width: 110px;
  height: 80px;
  border-radius: var(--radius-small);
  border: 1px solid var(--border-color);
  background: var(--input-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.result-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.results-details .result-name {
  font-weight: 600;
  color: var(--heading-color);
  margin-bottom: 4px;
}

.results-details .result-meta {
  font-size: 16.8px;
  color: var(--muted-text);
  margin-bottom: 8px;
}

.result-copy {
  padding: 0;
  font-size: 16px;
}

.results-download {
  width: 160px;
  text-align: right;
}

.results-download .button {
  width: 100%;
}

@media (max-width: 1024px) {
  .results-grid {
    margin-top: 24px;
  }

  .results-table {
    min-width: 520px;
  }

  .results-table thead th,
  .results-table td {
    padding: 10.4px 12px;
    font-size: 16.8px;
  }

  .results-preview {
    width: 110px;
  }

  .result-thumb {
    width: 90px;
    height: 68px;
  }

  .results-download {
    width: 100px;
    text-align: center;
  }

  .results-download .button {
    width: 44px;
    height: 44px;
    padding: 8px;
    font-size: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    line-height: 1;
  }

  .results-download .button i {
    margin: 0;
    font-size: 24px;
    line-height: 1;
    margin-left: 16.5px;
  }
}

@media (max-width: 768px) {
  .results-grid {
    margin-top: 16px;
  }

  .results-table {
    min-width: 420px;
  }

  .results-table thead th,
  .results-table td {
    padding: 8px 9.6px;
    font-size: 13.6px;
  }

  .results-details .result-name {
    font-size: 17.6px;
  }

  .results-details .result-meta {
    font-size: 15.2px;
  }
}

.result-link {
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
  color: var(--link);
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
}

.result-link:hover,
.result-link:focus {
  color: var(--heading-color);
}

.result-row.is-downloaded td {
  background: rgba(46, 204, 113, 0.12);
  box-shadow: inset 3px 0 0 rgba(46, 204, 113, 0.6);
}

.conversion-recommendations {
  margin-top: 32px;
  padding: 24px;
}

.conversion-recommendations h3 {
  margin: 0 0 16px 0;
  font-size: 22.4px;
  color: var(--heading-color);
}

.recommendations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.recommendation-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);
  background: var(--card-bg);
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.recommendation-card:hover {
  border-color: var(--link);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.recommendation-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(102, 126, 234, 0.1);
  color: var(--link);
  font-size: 24px;
  flex-shrink: 0;
}

.recommendation-content {
  flex: 1;
  min-width: 0;
}

.recommendation-content strong {
  display: block;
  margin-bottom: 4px;
  color: var(--heading-color);
  font-size: 17.6px;
}

.recommendation-content p {
  margin: 0;
  font-size: 16px;
  color: var(--muted-text);
  line-height: 1.4;
}

.recommendation-arrow {
  color: var(--muted-text);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.recommendation-card:hover .recommendation-arrow {
  transform: translateX(4px);
  color: var(--link);
}

@media (max-width: 1024px) {
  .recommendations-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
}

@media (max-width: 768px) {
  .recommendation-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    position: relative;
    padding-right: 40px;
  }

  .recommendation-content {
    width: 100%;
  }

  .recommendation-arrow {
    position: absolute;
    top: 1px;
    right: 1px;
    transform: none;
  }
}

.tool-guide,
.workflow,
.format-table,
.tool-extras .card,
.seo-section .card,
/* FAQ Section */
.faq-section {
  margin-top: 64px;
  padding: 48px 0;
}

.faq-section h2 {
  text-align: center;
  margin-bottom: 16px;
}

.faq-description {
  font-size: 25.6px;
  color: var(--muted-text, #666);
  text-align: center;
  max-width: 900px;
  margin: 0 auto 64px auto;
  line-height: 1.7;
}

[data-theme='dark'] .faq-description {
  color: var(--muted-text, #b0b0b0);
}

.faq-container {
  max-width: 900px;
  margin: 50px auto 0 auto;
  width: 100%;
  box-sizing: border-box;
}

.faq-item {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium, 12px);
  margin-bottom: 15px;
  overflow: hidden;
  transition: all 0.3s ease;
  width: 100%;
  box-sizing: border-box;
}

.faq-item:hover {
  border-color: var(--primary-blue, var(--link, #0066cc));
  box-shadow:
    0 4px 20px rgba(99, 102, 241, 0.15),
    0 0 0 1px rgba(99, 102, 241, 0.05) inset;
  transform: translateX(5px);
}

.faq-item[aria-expanded='true'] {
  border-color: var(--primary-blue, var(--link, #0066cc));
}

.faq-question {
  width: 100%;
  max-width: 100%;
  background: transparent;
  border: none !important;
  padding: 20px 25px;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  color: var(--heading-color);
  font-size: 1.15em;
  font-weight: 500;
  transition: color 0.3s ease;
  font-family: inherit;
  box-sizing: border-box;
  overflow: hidden;
  white-space: normal;
}

.faq-question span {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  max-width: 100% !important;
  word-wrap: break-word !important;
  overflow-wrap: anywhere !important;
  word-break: break-word !important;
  line-height: 1.5;
  white-space: normal !important;
  display: block;
}

.faq-question:hover {
  color: var(--primary-blue, var(--link, #0066cc));
}

.faq-item[aria-expanded='true'] .faq-question {
  color: var(--primary-blue, var(--link, #0066cc));
}

.faq-question i {
  font-size: 1.05em;
  color: var(--primary-blue, var(--link, #0066cc));
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.4s ease,
    padding 0.3s ease;
  padding: 0 25px;
}

.faq-item[aria-expanded='true'] .faq-answer,
.faq-item.faq-open .faq-answer {
  max-height: 1000px;
  padding: 0 25px 40px 25px;
}

.faq-item[aria-expanded='true'] .faq-question i,
.faq-item.faq-open .faq-question i {
  transform: rotate(180deg);
}

.faq-answer p {
  color: var(--muted-text);
  line-height: 1.7;
  font-size: 16.8px;
  margin: 0 0 12px 0;
}

.faq-answer p:last-child {
  margin-bottom: 16px;
}

.faq-answer strong {
  color: var(--primary-blue, var(--link, #0066cc));
  font-weight: 600;
}

[data-theme='dark'] .faq-item {
  background: var(--card-bg, #1e1e1e);
  border-color: var(--border-color, #404040);
}

[data-theme='dark'] .faq-item:hover {
  background: var(--card-bg, #1e1e1e);
  box-shadow:
    0 3px 15px rgba(99, 102, 241, 0.1),
    0 0 0 1px rgba(99, 102, 241, 0.05) inset;
}

[data-theme='dark'] .faq-item[aria-expanded='true'] {
  background: var(--card-bg, #1e1e1e);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.12);
}

[data-theme='dark'] .faq-question {
  color: var(--heading-color, #e0e0e0);
}

[data-theme='dark'] .faq-answer p {
  color: var(--muted-text, #b0b0b0);
}

@media (max-width: 768px) {
  .faq-item {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .faq-question {
    padding: 18px 20px;
    font-size: 1.05em;
    align-items: flex-start;
    gap: 15px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    white-space: normal;
  }

  .faq-question span {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: calc(100% - 30px) !important;
    padding-right: 0;
    word-wrap: break-word !important;
    overflow-wrap: anywhere !important;
    word-break: break-word !important;
    hyphens: auto;
    white-space: normal !important;
    display: block !important;
  }

  .faq-question i {
    flex-shrink: 0;
    flex-grow: 0;
    align-self: flex-start;
    margin-top: 32px;
    width: auto;
  }

  .faq-answer {
    padding: 0 20px;
  }

  .faq-answer {
    padding: 0 20px;
  }

  .faq-item[aria-expanded='true'] .faq-answer {
    padding: 0 20px 18px 20px;
  }
}

.workflow-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.workflow-steps .badge {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--link);
  color: #fff;
  font-weight: 700;
  margin-bottom: 8px;
}

.format-table table {
  width: 100%;
  border-collapse: collapse;
}

.format-table th,
.format-table td {
  border: 1px solid var(--border-color);
  padding: 12px;
  text-align: left;
}

.tool-extras {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 0;
}

.checklist li {
  margin-bottom: 8px;
  padding-left: 20px;
  position: relative;
}

.checklist li::before {
  content: '•';
  color: var(--link);
  position: absolute;
  left: 0;
}

.feature-pills {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.feature-pills li {
  padding: 6.4px 14.4px;
  border-radius: 999px;
  background: var(--input-bg);
  font-size: 16.8px;
}

.preset-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.button-pill {
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: transparent;
  padding: 6.4px 14.4px;
  font-size: 16px;
  cursor: pointer;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Modern Hero Section */
.modern-hero {
  padding: 64px 0 6px;
  background: linear-gradient(
    180deg,
    rgba(102, 126, 234, 0.05) 0%,
    transparent 100%
  );
  margin-bottom: 64px;
}

.hero-header {
  text-align: center;
  max-width: 1000px;
  margin: 0 auto 64px;
  padding: 0 32px;
}

.hero-header h1 {
  font-size: 56px;
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 24px 0;
  letter-spacing: -0.02em;
  background: linear-gradient(
    135deg,
    var(--heading-color, #1a1a1a) 0%,
    var(--link, #0066cc) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-header .lead {
  font-size: 24px;
  color: var(--muted-text);
  line-height: 1.6;
  margin-bottom: 32px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.hero-header .hero-features {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  justify-content: center;
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
}

.hero-left {
  position: relative;
}

.hero-animation {
  position: relative;
  height: 400px;
  margin-bottom: 32px;
  margin-top: -32px;
}

.floating-shapes {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.shape {
  position: absolute;
  border-radius: 50%;
  background: var(--gradient-primary);
  opacity: 0.1;
  animation: float 20s infinite ease-in-out;
}

.shape-1 {
  width: 120px;
  height: 120px;
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.shape-2 {
  width: 80px;
  height: 80px;
  top: 60%;
  left: 20%;
  animation-delay: 2s;
  background: var(--gradient-secondary);
}

.shape-3 {
  width: 100px;
  height: 100px;
  top: 30%;
  right: 15%;
  animation-delay: 4s;
  background: var(--gradient-accent);
}

.shape-4 {
  width: 60px;
  height: 60px;
  bottom: 20%;
  right: 30%;
  animation-delay: 6s;
}

.shape-5 {
  width: 90px;
  height: 90px;
  bottom: 10%;
  left: 50%;
  animation-delay: 8s;
  background: var(--gradient-secondary);
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(20px, -30px) scale(1.1);
  }
  50% {
    transform: translate(-15px, 20px) scale(0.9);
  }
  75% {
    transform: translate(30px, 10px) scale(1.05);
  }
}

.hero-icon-grid {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  width: 300px;
}

.icon-item {
  width: 80px;
  height: 80px;
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--link);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  animation: iconPulse 3s infinite ease-in-out;
  transition: all 0.3s ease;
}

.icon-item:nth-child(1) {
  animation-delay: 0s;
}
.icon-item:nth-child(2) {
  animation-delay: 0.5s;
}
.icon-item:nth-child(3) {
  animation-delay: 1s;
}
.icon-item:nth-child(4) {
  animation-delay: 1.5s;
}
.icon-item:nth-child(5) {
  animation-delay: 2s;
}
.icon-item:nth-child(6) {
  animation-delay: 2.5s;
}

@keyframes iconPulse {
  0%,
  100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  }
  50% {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.3);
  }
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-content .lead {
  font-size: 20.8px;
  color: var(--muted-text);
  line-height: 1.6;
  margin-bottom: 32px;
}

.hero-features {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--heading-color);
  font-weight: 600;
}

.feature-item i {
  color: var(--link);
  font-size: 19.2px;
}

.hero-right {
  position: relative;
}

.modern-dropzone {
  min-height: 240px;
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-large);
  padding: 32px;
  margin-bottom: 24px;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.modern-dropzone::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(102, 126, 234, 0.08) 50%,
    transparent 100%
  );
  transition: left 0.5s ease;
  pointer-events: none;
}

.modern-dropzone:hover {
  border-color: var(--link);
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.15);
  background: rgba(102, 126, 234, 0.02);
}

.modern-dropzone:hover::before {
  left: 100%;
}

.upload-actions {
  text-align: center;
}

.upload-actions .button {
  width: 100%;
  justify-content: center;
  padding: 16px 32px;
  font-size: 20px;
}

/* Stats Section */
.stats-section {
  padding: 64px 0;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}

.stats-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -10%;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: var(--gradient-primary);
  opacity: 0.05;
  animation: statFloat1 20s infinite ease-in-out;
}

.stats-section::after {
  content: '';
  position: absolute;
  bottom: -30%;
  right: -5%;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: var(--gradient-secondary);
  opacity: 0.05;
  animation: statFloat2 25s infinite ease-in-out;
}

@keyframes statFloat1 {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(30px, -40px) scale(1.1);
  }
  66% {
    transform: translate(-20px, 30px) scale(0.9);
  }
}

@keyframes statFloat2 {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(-40px, 50px) scale(1.15);
  }
}

.stats-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 1;
}

.stat-item {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);
  padding: 40px 32px;
  text-align: center;
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(30px) scale(0.9);
  transition: all 0.3s ease;
  cursor: default;
}

.stat-item.animate-in {
  animation: statFadeIn 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.stat-item:nth-child(1).animate-in {
  animation-delay: 0.1s;
}

.stat-item:nth-child(2).animate-in {
  animation-delay: 0.2s;
}

.stat-item:nth-child(3).animate-in {
  animation-delay: 0.3s;
}

@keyframes statFadeIn {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }
  60% {
    transform: translateY(-5px) scale(1.02);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.stat-item::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(102, 126, 234, 0.1) 0%,
    transparent 70%
  );
  transform: translate(-50%, -50%);
  transition:
    width 0.6s ease,
    height 0.6s ease;
  pointer-events: none;
}

.stat-item.animate-in::after {
  width: 200px;
  height: 200px;
  animation: statPulse 2s ease-out;
}

@keyframes statPulse {
  0% {
    width: 0;
    height: 0;
    opacity: 0.8;
  }
  50% {
    opacity: 0.4;
  }
  100% {
    width: 200px;
    height: 200px;
    opacity: 0;
  }
}

.stat-item .stat-value {
  position: relative;
  z-index: 1;
  display: inline-block;
  transition: transform 0.3s ease;
}

.stat-item .stat-value.counter-complete {
  animation: counterComplete 0.6s ease;
}

@keyframes counterComplete {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.15);
  }
  100% {
    transform: scale(1);
  }
}

.stat-item .stat-value {
  display: block;
  font-size: 56px;
  font-weight: 800;
  background: linear-gradient(
    135deg,
    var(--heading-color, #1a1a1a) 0%,
    var(--link, #0066cc) 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
  line-height: 1;
  letter-spacing: -0.02em;
}

.stat-item .stat-label {
  display: block;
  text-transform: uppercase;
  font-size: 16.8px;
  letter-spacing: 0.15em;
  color: var(--muted-text);
  font-weight: 700;
  margin-bottom: 12px;
}

.stat-item .stat-description {
  color: var(--muted-text);
  font-size: 20px;
  line-height: 1.6;
  margin: 0;
}

.stat-item:hover {
  transform: translateY(-4px) scale(1);
  border-color: var(--link);
  box-shadow: 0 12px 32px rgba(102, 126, 234, 0.15);
  background: var(--card-bg);
}

/* Tools Section */
.tools-section {
  padding: 32px 0;
  margin-bottom: 64px;
}

.tools-section .section-header {
  text-align: center;
  margin-bottom: 24px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 32px;
}

.tools-section .section-header .lead {
  font-size: 24px;
  color: var(--muted-text);
  line-height: 1.6;
  margin-bottom: 32px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* SEO Content Section */
.seo-content-section {
  padding: 64px 0;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(102, 126, 234, 0.03) 100%
  );
}

.seo-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.seo-container > h2 {
  text-align: center;
  margin-bottom: 48px;
}

/* Intro Section */
.seo-intro {
  margin-bottom: 64px;
  text-align: center;
}

.seo-intro .lead {
  font-size: 24px;
  color: var(--muted-text);
  line-height: 1.6;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 24px;
}

.seo-intro .lead:last-child {
  margin-bottom: 0;
}

/* Features Grid */
.seo-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-bottom: 64px;
}

.seo-feature-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);
  padding: 32px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.seo-feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(102, 126, 234, 0.15);
  border-color: rgba(102, 126, 234, 0.4);
}

.feature-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 24px;
  background: var(--gradient-primary);
  border-radius: var(--radius-large);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: white;
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
  transition: all 0.3s ease;
}

.seo-feature-card:hover .feature-icon {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 12px 32px rgba(102, 126, 234, 0.4);
}

.seo-feature-card h3 {
  font-size: 20.8px;
  margin-bottom: 16px;
  color: var(--heading-color);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.seo-feature-card p {
  color: var(--text-color);
  line-height: 1.7;
  font-size: 16.8px;
  margin: 0;
}

/* Formats Section */
.seo-formats-section {
  margin-bottom: 64px;
}

.seo-formats-section h2 {
  text-align: center;
  margin-bottom: 16px;
}

.seo-formats-section .lead {
  font-size: 24px;
  color: var(--muted-text);
  line-height: 1.6;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 32px;
}

.format-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.format-item {
  padding: 32px 24px;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
}

.format-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(102, 126, 234, 0.15);
  border-color: rgba(102, 126, 234, 0.3);
}

.format-ext {
  display: block;
  font-size: 22.4px;
  color: var(--heading-color);
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
  font-family: 'Courier New', monospace;
  text-transform: uppercase;
}

.format-use {
  font-size: 16.8px;
  color: var(--text-color);
  line-height: 1.6;
  margin: 8px 0;
  flex-grow: 1;
}

.format-alpha {
  display: inline-flex;
  align-items: center;
  padding: 6.4px 16px;
  background: var(--gradient-primary);
  color: white;
  border-radius: 999px;
  font-size: 14.4px;
  font-weight: 600;
  margin-top: auto;
  width: fit-content;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.25);
  transition: all 0.3s ease;
}

.format-item:hover .format-alpha {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.35);
}

/* Workflow Section */
.seo-workflow-section {
  margin-bottom: 32px;
}

.seo-workflow-section h2 {
  text-align: center;
  margin-bottom: 16px;
}

.seo-workflow-section .lead {
  font-size: 24px;
  color: var(--muted-text);
  line-height: 1.6;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 48px;
  text-align: center;
}

.workflow-roadmap {
  display: grid;
  grid-template-columns: 1fr 48px 1fr 48px 1fr 48px 1fr;
  column-gap: 12px;
  row-gap: 0;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  align-items: center;
}

.workflow-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);
  padding: 32px 24px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  z-index: 1;
  margin: 0;
}

.workflow-card:first-child {
  margin-left: 0;
}

.workflow-card:last-child {
  margin-right: 0;
}

.workflow-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(102, 126, 234, 0.2);
  border-color: rgba(102, 126, 234, 0.4);
}

.workflow-number {
  width: 72px;
  height: 72px;
  margin: 0 auto 24px;
  border-radius: 50%;
  background: var(--gradient-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(102, 126, 234, 0.35);
  transition: all 0.3s ease;
  position: relative;
  z-index: 2;
}

.workflow-card:hover .workflow-number {
  transform: scale(1.1);
  box-shadow: 0 12px 32px rgba(102, 126, 234, 0.45);
}

.workflow-card h4 {
  font-size: 22.4px;
  margin-bottom: 16px;
  color: var(--heading-color);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.workflow-card p {
  color: var(--text-color);
  line-height: 1.7;
  font-size: 16.8px;
  margin: 0;
}

.workflow-connector {
  position: relative;
  align-self: center;
  justify-self: stretch;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
  opacity: 0.55;
  display: flex;
  align-items: center;
}

.workflow-connector::after {
  content: none;
  display: none;
}

.workflow-card:last-child ~ .workflow-connector {
  display: none;
}

@media (max-width: 1024px) {
  .workflow-roadmap {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }

  .workflow-card {
    margin: 0;
  }

  .workflow-connector {
    display: none;
  }

  .workflow-card:nth-child(2) {
    position: relative;
  }

  .workflow-card:nth-child(2)::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 1px;
    background: linear-gradient(180deg, var(--gradient-primary));
    opacity: 0.4;
  }

  .workflow-card:nth-child(2)::before {
    content: '↓';
    position: absolute;
    bottom: -1.5px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--link);
    font-size: 19.2px;
    font-weight: 700;
  }
}

@media (max-width: 768px) {
  .workflow-roadmap {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .workflow-card {
    margin: 0 0 32px 0;
  }

  .workflow-card:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 1px;
    background: linear-gradient(180deg, var(--gradient-primary));
    opacity: 0.4;
  }

  .workflow-card:not(:last-child)::before {
    content: '↓';
    position: absolute;
    bottom: -1.5px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--link);
    font-size: 19.2px;
    font-weight: 700;
  }

  .workflow-card:nth-child(2)::after,
  .workflow-card:nth-child(2)::before {
    display: block;
  }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero-header h1 {
    font-size: 48px;
  }

  .hero-container {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .hero-animation {
    height: 300px;
  }

  .tools-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}

@media (max-width: 768px) {
  .modern-hero {
    padding: 32px 0 64px;
  }

  .hero-header {
    margin-bottom: 32px;
    padding: 0 16px;
  }

  .hero-header h1 {
    font-size: 40px;
  }

  .hero-container {
    padding: 0 16px;
  }

  .hero-features {
    flex-direction: column;
    gap: 16px;
  }

  .tools-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    padding: 0 16px;
  }

  .tool-card {
    padding: 24px 16px;
  }

  .tool-icon {
    width: 48px;
    height: 48px;
    font-size: 24px;
  }

  .tool-card h3 {
    font-size: 16px;
  }

  .seo-features-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .seo-feature-card {
    padding: 24px;
  }

  .workflow-card {
    padding: 24px;
  }

  .format-grid {
    grid-template-columns: 1fr;
  }
}
