/* Reset & Base Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent !important;
  -webkit-touch-callout: none;
}

/* Completely Remove Browser Blue Tap Highlight Box & Default Focus Ring */
button,
input,
select,
textarea,
a,
label,
.dropzone,
.compact-card,
.single-card,
.badge-pill,
.format-tab-btn,
.mini-tab-btn,
.btn,
.choose-btn,
.theme-toggle-btn,
.btn-start-action,
.btn-add-images,
.btn-clear-all,
.btn-download-all,
.btn-download-single,
.btn-remove-single {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

button:focus,
button:active,
input:focus,
input:active,
select:focus,
a:focus {
  outline: none !important;
}

body {
  font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: #f8fafc;
  color: #0f172a;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color 0.3s ease, color 0.3s ease;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Compact Modern Header */
.header {
  width: 100%;
  padding: 10px 24px;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.03);
  transition: background-color 0.3s ease, border-color 0.3s ease;
  contain: layout style;
}

.header-container {
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 42px;
}

/* Aligned Container Classes */
.compact-header-container {
  max-width: 480px;
}

.single-header-container {
  max-width: 640px;
}

.hero-header-container {
  max-width: 920px;
}

/* Perfectly Scaled Brand Logo */
.logo-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  user-select: none;
  cursor: pointer;
  height: 38px;
}

.logo-icon-box {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #0066ff 0%, #0041b3 100%);
  box-shadow: 0 3px 10px rgba(0, 102, 255, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.logo-icon-box svg {
  width: 24px;
  height: 24px;
}

.logo-brand:hover .logo-icon-box {
  transform: scale(1.06) rotate(-3deg);
  box-shadow: 0 5px 14px rgba(0, 102, 255, 0.38);
}

.logo-title-group {
  display: flex;
  align-items: center;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1;
}

.logo-text-primary {
  color: #0f172a;
  transition: color 0.3s ease;
}

.logo-text-accent {
  color: #0066ff;
  font-weight: 800;
  margin-left: 1px;
}

/* Header Actions & Modern Theme Button */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-header-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 11px;
  border-radius: 20px;
  background: rgba(0, 102, 255, 0.08);
  color: #0066ff;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.dark-theme .nav-header-btn {
  background: rgba(255, 255, 255, 0.08);
  color: #38bdf8;
}

.nav-header-btn:hover {
  background: rgba(0, 102, 255, 0.16);
  transform: translateY(-1px);
}

.dark-theme .nav-header-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}

.theme-toggle-btn {
  background: #f0f7ff;
  border: 1.5px solid #bae6fd;
  color: #0066ff;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  will-change: transform;
  transform: translateZ(0);
  transition: background-color 0.25s ease, border-color 0.25s ease, transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 2px 8px rgba(0, 102, 255, 0.08);
}

.theme-toggle-btn:hover {
  background: #0066ff;
  color: #ffffff;
  border-color: #0052cc;
  transform: scale(1.08) rotate(8deg);
  box-shadow: 0 4px 14px rgba(0, 102, 255, 0.35);
}

.theme-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  will-change: transform, opacity;
  transform: translateZ(0);
  transition: transform 0.25s ease;
}

/* GPU Hardware Accelerated 360 Degree Spin & Pop Animation for Theme Toggle Icon */
.theme-toggle-btn.theme-animating .theme-icon {
  animation: themeIconSpinPop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes themeIconSpinPop {
  0% {
    transform: scale(0.5) rotate(0deg);
    opacity: 0.3;
  }
  50% {
    transform: scale(1.35) rotate(180deg);
    opacity: 1;
  }
  100% {
    transform: scale(1) rotate(360deg);
    opacity: 1;
  }
}

/* Main Layout */
.main-content {
  flex: 1;
  max-width: 1060px;
  width: 100%;
  margin: 0 auto;
  padding: 28px 20px 60px;
}

.hero-grid {
  display: flex;
  gap: 32px;
  align-items: stretch;
  justify-content: center;
  flex-wrap: wrap;
}

/* Left: Dropzone Box */
.upload-section {
  flex: 1 1 340px;
  max-width: 380px;
  display: flex;
}

.dropzone {
  width: 100%;
  min-height: 290px;
  border: 3px dashed #0066ff;
  border-radius: 20px;
  background-color: #ffffff;
  box-shadow: 0 10px 32px rgba(0, 102, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  padding: 32px 24px;
}

.dropzone:hover, .dropzone.dragover {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 50%, #e0f2fe 100%);
  border-color: #0052cc;
  transform: translateY(-3px);
  box-shadow: 0 18px 44px rgba(0, 102, 255, 0.22), 0 0 0 4px rgba(0, 102, 255, 0.12);
}

.file-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
}

.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  pointer-events: none;
}

.drop-title {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.3px;
  transition: color 0.3s ease;
}

.or-text {
  font-size: 13px;
  font-weight: 800;
  color: #334155;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
}

/* ANIMATED EDGE LIGHTING BUTTON */
.choose-btn {
  pointer-events: auto;
  background: linear-gradient(135deg, #0066ff 0%, #0044bb 100%);
  color: #ffffff;
  border: none;
  padding: 12px 28px;
  border-radius: 20px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  position: relative;
  z-index: 10;
  animation: glowEdgePulse 2.5s infinite ease-in-out;
  transition: all 0.25s ease;
}

.choose-btn:hover {
  background: linear-gradient(135deg, #0052cc 0%, #003399 100%);
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 10px 30px rgba(0, 102, 255, 0.75), 0 0 20px 6px rgba(56, 189, 248, 0.9);
}

/* Right: Features Section */
.features-section {
  flex: 1 1 420px;
  max-width: 490px;
  display: flex;
}

.features-card {
  width: 100%;
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  padding: 32px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.features-title {
  font-family: 'Newsreader', 'Georgia', serif;
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  text-align: center;
  line-height: 1.25;
  margin-bottom: 24px;
  transition: color 0.3s ease;
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 20px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px;
  border-radius: 8px;
  transition: all 0.2s ease;
  cursor: default;
}

.feature-item:hover {
  background-color: rgba(0, 102, 255, 0.08);
  transform: translateX(4px);
}

.feature-full {
  grid-column: 1 / -1;
}

.feature-icon {
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  transition: transform 0.2s ease;
}

.feature-item:hover .feature-icon {
  transform: scale(1.25) rotate(5deg);
}

.feature-text {
  font-size: 14px;
  font-weight: 600;
  color: #1e293b;
  transition: color 0.3s ease;
}

/* Single Card Layout */
.single-card-wrapper {
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  animation: cardFadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.single-card {
  width: 100%;
  border: 3px dashed #0066ff;
  border-radius: 24px;
  background-color: #ffffff;
  box-shadow: 0 10px 36px rgba(0, 102, 255, 0.15);
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.single-card:hover, .single-card.dragover {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 50%, #e0f2fe 100%);
  border-color: #0052cc;
  box-shadow: 0 18px 44px rgba(0, 102, 255, 0.24), 0 0 0 4px rgba(0, 102, 255, 0.12);
}

.single-card-upload {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-bottom: 24px;
}

.card-divider {
  width: 85%;
  height: 1px;
  background: linear-gradient(90deg, transparent, #cbd5e1, transparent);
  margin: 8px 0 24px;
}

.single-card-features {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.single-features-grid {
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
  gap: 14px 24px;
}

/* MODERN COMPACT UPLOAD CARD STYLING (MAX-WIDTH: 480PX) */
.compact-card-wrapper {
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  animation: cardFadeIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  contain: layout style;
}

.compact-card {
  width: 100%;
  border: 3px dashed #0066ff;
  border-radius: 22px;
  background-color: #ffffff;
  box-shadow: 0 12px 36px rgba(0, 102, 255, 0.16), 0 2px 8px rgba(0, 0, 0, 0.04);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  cursor: pointer;
  contain: layout style;
  backface-visibility: hidden;
  transform: translateZ(0);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.compact-card:hover, .compact-card.dragover {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 50%, #e0f2fe 100%);
  border-color: #0052cc;
  transform: translateY(-4px);
  box-shadow: 0 20px 48px rgba(0, 102, 255, 0.24), 0 0 0 4px rgba(0, 102, 255, 0.12);
}

/* High Visibility Animated Upload Icon Glow */
.compact-icon-glow {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, #0066ff 0%, #0041b3 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  box-shadow: 0 6px 18px rgba(0, 102, 255, 0.32);
  animation: floatIcon 3s ease-in-out infinite;
  will-change: transform;
  transform: translateZ(0);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.compact-card:hover .compact-icon-glow {
  transform: scale(1.12) rotate(-5deg);
  box-shadow: 0 8px 22px rgba(0, 102, 255, 0.45);
}

.compact-drop-title {
  font-size: 21px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.4px;
  margin-bottom: 4px;
  transition: color 0.3s ease;
}

.compact-subtext {
  font-size: 13.5px;
  color: #334155;
  margin-bottom: 18px;
  font-weight: 700;
  transition: color 0.3s ease;
}

.modern-choose-btn {
  background: linear-gradient(135deg, #0066ff 0%, #0052cc 100%);
  padding: 11px 28px;
  font-size: 14.5px;
  border-radius: 20px;
  font-weight: 700;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 16px rgba(0, 102, 255, 0.35);
}

.compact-header-tag {
  width: 100%;
  margin: 22px 0 16px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.compact-header-tag::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 1.5px;
  background: #cbd5e1;
  z-index: 1;
  transition: background 0.3s ease;
}

.compact-header-tag span {
  position: relative;
  z-index: 2;
  background: #ffffff;
  padding: 0 12px;
  font-size: 11.5px;
  font-weight: 800;
  color: #0284c7;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  transition: background 0.3s ease, color 0.3s ease;
}

.compact-card:hover .compact-header-tag span {
  background: #e0f2fe;
  color: #0066ff;
}

.compact-badges-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 2px;
}

/* HIGH CONTRAST & VISIBILITY PILL BADGES */
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  color: #0f172a;
  font-size: 12.5px;
  font-weight: 800;
  padding: 6px 13px;
  border-radius: 20px;
  border: 1.5px solid #cbd5e1;
  cursor: pointer;
  user-select: none;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  z-index: 10;
}

.badge-pill:hover {
  background: #0066ff;
  color: #ffffff;
  border-color: #0052cc;
  transform: translateY(-4px) scale(1.08);
  box-shadow: 0 8px 18px rgba(0, 102, 255, 0.38);
}

.pill-icon {
  font-size: 13.5px;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.badge-pill:hover .pill-icon {
  transform: scale(1.35) rotate(10deg);
}

.badge-full {
  width: auto;
}

/* ATTRACTIVE KEYFRAME ANIMATIONS & LIGHTING GLOW */
@keyframes cardFadeIn {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

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

@keyframes glowEdgePulse {
  0%, 100% {
    box-shadow: 0 4px 16px rgba(0, 102, 255, 0.4), 0 0 0 2px rgba(56, 189, 248, 0.7);
  }
  50% {
    box-shadow: 0 8px 26px rgba(0, 102, 255, 0.75), 0 0 16px 4px rgba(56, 189, 248, 0.9), 0 0 0 3px rgba(255, 255, 255, 0.8);
  }
}

/* HIGH-PERFORMANCE 360 DEGREE ROTATING SPINNER FOR START BUTTON */
.btn-loader-spinner {
  width: 18px;
  height: 18px;
  border: 2.8px solid rgba(255, 255, 255, 0.35);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spinLoader 0.75s linear infinite;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

@keyframes spinLoader {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* WORKSPACE COMPRESSION SETTINGS CARD (WITH MATCHED 3PX DASHED BLUE BORDER) */
.workspace-section {
  max-width: 480px;
  width: 100%;
  margin: 0 auto;
  background: #ffffff;
  border: 3px dashed #0066ff;
  border-radius: 22px;
  padding: 28px 24px;
  box-shadow: 0 14px 40px rgba(0, 102, 255, 0.12);
  animation: fadeIn 0.3s ease;
  contain: layout style;
  backface-visibility: hidden;
  transform: translateZ(0);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.workspace-section:hover {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 50%, #e0f2fe 100%);
  border-color: #0052cc;
  transform: translateY(-3px);
  box-shadow: 0 20px 48px rgba(0, 102, 255, 0.24), 0 0 0 4px rgba(0, 102, 255, 0.12);
}

.compression-settings-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  width: 100%;
}

/* 1. Format Toggle Box (FULL CARD SPANNING) */
.format-toggle-container {
  display: flex;
  width: 100%;
  height: 50px;
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: border-color 0.2s ease;
}

.format-tab-btn {
  flex: 1;
  border: none;
  background: #ffffff;
  color: #0f172a;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 4px 10px;
  transition: all 0.2s ease;
}

.format-tab-btn + .format-tab-btn {
  border-left: 1.5px solid #cbd5e1;
}

.format-tab-btn .tab-title {
  font-size: 15px;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: -0.2px;
  line-height: 1.1;
}

.format-tab-btn .tab-sub {
  font-size: 11.5px;
  font-weight: 700;
  color: #334155;
  margin-top: 1px;
}

/* Active Format Tab (Vibrant Golden Yellow with Solid Black Text) */
.format-tab-btn.active {
  background-color: #ffb700;
  color: #000000;
}

.format-tab-btn.active .tab-title {
  color: #000000;
  font-weight: 900;
}

.format-tab-btn.active .tab-sub {
  color: #000000;
  font-weight: 800;
}

.format-tab-btn:hover:not(.active) {
  background-color: #f1f5f9;
}

/* 2. Selected Files Summary Box (FULL CARD SPANNING) */
.selected-summary-box {
  display: flex;
  width: 100%;
  height: 48px;
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  background: #f8fafc;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  transition: all 0.3s ease;
}

.summary-item {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 4px 10px;
  font-size: 13.5px;
  font-weight: 800;
  color: #0f172a;
}

.summary-svg {
  color: #0066ff;
  stroke-width: 2.3px;
  flex-shrink: 0;
}

.summary-divider {
  width: 1.5px;
  height: 55%;
  align-self: center;
  background: #cbd5e1;
}

.summary-text {
  color: #0f172a;
  font-weight: 700;
}

.summary-text strong {
  color: #0066ff;
  font-weight: 900;
}

/* 3. Single Horizontal Line Controls (FULL CARD SPANNING) */
.single-line-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  height: 48px;
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  padding: 6px 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.mini-mode-toggle {
  display: flex;
  background: #cbd5e1;
  border-radius: 9px;
  padding: 2.5px;
  gap: 2px;
}

.mini-tab-btn {
  border: none;
  background: transparent;
  color: #1e293b;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 7px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.mini-tab-btn.active {
  background: #0066ff;
  color: #ffffff;
  font-weight: 800;
  box-shadow: 0 2px 6px rgba(0, 102, 255, 0.35);
}

.dynamic-row-input {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  justify-content: flex-end;
}

.row-label {
  font-size: 13px;
  font-weight: 900;
  color: #0f172a;
  white-space: nowrap;
}

.mini-slider {
  accent-color: #0066ff;
  width: 105px;
  cursor: pointer;
}

.mini-size-input {
  width: 68px;
  padding: 4px 8px;
  border-radius: 6px;
  border: 1.5px solid #94a3b8;
  background-color: #ffffff;
  font-size: 12.5px;
  font-weight: 800;
  color: #0f172a;
  outline: none;
}

.mini-unit-select {
  padding: 4px 6px;
  border-radius: 6px;
  border: 1.5px solid #94a3b8;
  background-color: #ffffff;
  font-size: 12.5px;
  font-weight: 800;
  color: #0f172a;
  outline: none;
  cursor: pointer;
}

/* 4. EMERALD GREEN Start Compression Button (WITH LIVE PROGRESS FILL BAR) */
.btn-start-action {
  width: 100%;
  height: 48px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  padding: 8px 18px;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.3px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.32);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-start-action:hover {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.45);
}

.btn-start-action.compressing-mode {
  background-color: #0d4230;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.btn-start-action.compressing-mode::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: var(--progress, 0%);
  background: linear-gradient(90deg, #10b981 0%, #059669 100%);
  transition: width 0.25s ease-out;
  z-index: 1;
}

.btn-content-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-start-action .start-icon {
  font-size: 15px;
  font-weight: 900;
  transition: transform 0.2s ease;
}

.btn-start-action:hover .start-icon {
  transform: translateX(4px);
}

/* 5. CUSTOM HIGH-CONTRAST SECONDARY ACTIONS (FULL CARD SPANNING) */
.workspace-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin-top: 2px;
}

.btn-add-images {
  flex: 1;
  height: 42px;
  padding: 0 12px;
  font-size: 13.5px;
  font-weight: 800;
  color: #065f46;
  background-color: #d1fae5;
  border: 1.5px solid #34d399;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-add-images:hover {
  background-color: #10b981;
  border-color: #059669;
  color: #ffffff;
  transform: translateY(-1.5px);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.3);
}

.btn-clear-all {
  flex: 1;
  height: 42px;
  padding: 0 12px;
  font-size: 13.5px;
  font-weight: 800;
  color: #991b1b;
  background-color: #fee2e2;
  border: 1.5px solid #f87171;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-clear-all:hover {
  background-color: #ef4444;
  border-color: #dc2626;
  color: #ffffff;
  transform: translateY(-1.5px);
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.3);
}

/* STEP 3: ULTRA-COMPACT RESULT PAGE CARD WITH GRAND ENTRY ANIMATION */
.result-section {
  max-width: 480px;
  width: 100%;
  margin: 0 auto;
  background: #ffffff;
  border: 3px dashed #0066ff;
  border-radius: 22px;
  padding: 18px 20px;
  box-shadow: 0 14px 40px rgba(0, 102, 255, 0.12);
  display: flex;
  flex-direction: column;
  gap: 12px;
  contain: layout style;
  backface-visibility: hidden;
  transform: translateZ(0);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* HIGH-IMPACT GRAND CELEBRATION ENTRY ANIMATION (1.25s Elastic Bounce & Glowing Pulse) */
.result-section.animate-grand-entry {
  animation: grandResultEntry 1.25s cubic-bezier(0.175, 0.885, 0.32, 1.25) forwards;
}

@keyframes grandResultEntry {
  0% {
    opacity: 0;
    transform: scale(0.72) translateY(50px);
    box-shadow: 0 0 0 rgba(0, 102, 255, 0);
  }
  45% {
    opacity: 1;
    transform: scale(1.05) translateY(-8px);
    box-shadow: 0 0 45px rgba(0, 102, 255, 0.45), 0 0 0 6px rgba(0, 102, 255, 0.2);
  }
  75% {
    transform: scale(0.98) translateY(2px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
    box-shadow: 0 14px 40px rgba(0, 102, 255, 0.16);
  }
}

.result-section:hover {
  background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 50%, #e0f2fe 100%);
  border-color: #0052cc;
  transform: translateY(-3px);
  box-shadow: 0 20px 48px rgba(0, 102, 255, 0.24), 0 0 0 4px rgba(0, 102, 255, 0.12);
}

/* COMPACT HEADER WITH INLINE SPINNING 🎉 EMOJI */
.result-header {
  text-align: center;
  padding-bottom: 6px;
  border-bottom: 1.5px solid #e2e8f0;
}

.pop-emoji {
  display: inline-block;
  font-size: 22px;
  vertical-align: middle;
}

.animate-grand-entry .pop-emoji {
  animation: emojiInlinePop 1.25s cubic-bezier(0.175, 0.885, 0.32, 1.35) forwards;
}

@keyframes emojiInlinePop {
  0% {
    opacity: 0;
    transform: scale(0) rotate(-720deg);
  }
  60% {
    opacity: 1;
    transform: scale(1.5) rotate(25deg);
  }
  80% {
    transform: scale(0.9) rotate(-10deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

.result-title {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  line-height: 1.2;
}

.animate-grand-entry .result-title {
  animation: titleGrandSlide 0.9s cubic-bezier(0.175, 0.885, 0.32, 1.2) 0.1s both;
}

@keyframes titleGrandSlide {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.85);
  }
  70% {
    opacity: 1;
    transform: translateY(-3px) scale(1.04);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.result-subtext {
  font-size: 12.5px;
  color: #475569;
  margin-top: 1px;
  font-weight: 700;
}

.animate-grand-entry .result-subtext {
  animation: subtextGrandLift 0.8s ease 0.25s both;
}

@keyframes subtextGrandLift {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ULTRA-COMPACT BATCH RESULT STATS SUMMARY STRIP WITH MODERN SVG ICONS */
.result-stats-strip {
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 100%;
  height: 32px;
  background: #f0f7ff;
  border: 1.5px solid #bae6fd;
  border-radius: 10px;
  padding: 0 10px;
  font-size: 11.5px;
  font-weight: 800;
  color: #0f172a;
}

.stat-pill {
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.strip-icon {
  stroke: #0066ff;
  flex-shrink: 0;
}

.strip-icon-green {
  stroke: #10b981;
  flex-shrink: 0;
}

.stat-pill strong {
  color: #0066ff;
  font-weight: 900;
}

.stat-divider {
  width: 1px;
  height: 55%;
  background: #bae6fd;
}

.stat-saved-badge {
  background: #d1fae5;
  color: #047857;
  font-size: 10.5px;
  font-weight: 900;
  padding: 1px 6px;
  border-radius: 8px;
  margin-left: 2px;
}

.animate-grand-entry .batch-card {
  animation: batchCardCascade 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.2) 0.3s both;
}

@keyframes batchCardCascade {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.94);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.result-actions {
  display: flex;
  gap: 10px;
  margin-top: 2px;
}

.btn-download-all {
  flex: 1.2;
  height: 42px;
  padding: 0 16px;
  font-size: 14px;
  font-weight: 900;
  background: linear-gradient(135deg, #0066ff 0%, #0041b3 100%);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 102, 255, 0.3);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-download-all:hover {
  background: linear-gradient(135deg, #0052cc 0%, #003399 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 102, 255, 0.42);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.btn-primary {
  background-color: #0066ff;
  color: #ffffff;
}

.btn-primary:hover {
  background-color: #0052cc;
}

.btn-secondary {
  background-color: #f1f5f9;
  color: #0f172a;
  border: 1px solid #cbd5e1;
}

.btn-secondary:hover {
  background-color: #e2e8f0;
}

/* BATCH LIST: COMPACT ULTRA-CLEAN 3-ITEM MAXIMUM VISIBLE LAYOUT */
.batch-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-height: 245px;
  overflow-y: auto;
  padding-right: 4px;
}

/* Custom Sleek Scrollbar */
.batch-list::-webkit-scrollbar {
  width: 5px;
}

.batch-list::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 10px;
}

.batch-list::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}

.batch-list::-webkit-scrollbar-thumb:hover {
  background: #0066ff;
}

/* HIGH-PERFORMANCE COMPACT BATCH CARD (EXACTLY 68PX HEIGHT) */
.batch-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  height: 68px;
  border: 1.5px solid #cbd5e1;
  border-radius: 12px;
  background: #ffffff;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.batch-card:hover {
  border-color: #0066ff;
  box-shadow: 0 4px 14px rgba(0, 102, 255, 0.14);
}

.item-preview {
  width: 46px;
  height: 46px;
  border-radius: 8px;
  object-fit: cover;
  background: #f1f5f9;
  flex-shrink: 0;
  border: 1px solid #e2e8f0;
}

.item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}

.item-name {
  font-size: 13.5px;
  font-weight: 800;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
  max-width: 220px;
}

.item-stats {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.stat-orig {
  color: #64748b;
  font-weight: 700;
}

.stat-arrow {
  color: #0066ff;
  font-size: 11px;
  font-weight: 900;
}

.stat-comp {
  color: #0f172a;
  font-weight: 800;
}

.badge-saved {
  background-color: #e0f2fe;
  color: #0284c7;
  padding: 1.5px 7px;
  border-radius: 8px;
  font-weight: 900;
  font-size: 11px;
  margin-left: 2px;
}

/* COMPACT ACTION BUTTONS GROUP & SQUARE DOWNLOAD ICON BUTTON */
.item-actions-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-remove-single {
  background: #fef2f2;
  border: 1.5px solid #fecaca;
  color: #ef4444;
  width: 30px;
  height: 34px;
  border-radius: 99px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-remove-single:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #dc2626;
  transform: scale(1.06);
}

.btn-download-single {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, #0066ff 0%, #0041b3 100%);
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 3px 10px rgba(0, 102, 255, 0.28);
  text-decoration: none;
}

.btn-download-single:hover {
  background: linear-gradient(135deg, #0052cc 0%, #003399 100%);
  transform: scale(1.08) translateY(-1px);
  box-shadow: 0 5px 14px rgba(0, 102, 255, 0.42);
}

.btn-download-single svg {
  stroke: #ffffff;
  stroke-width: 2.5px;
}

/* ==========================================================================
   DARK THEME HIGH-CONTRAST OVERHAUL (100% CRYSTAL VISIBILITY IN NIGHT MODE)
   ========================================================================== */
body.dark-theme {
  background-color: #090d16;
  color: #ffffff;
}

body.dark-theme .header {
  background-color: #0f172a;
  border-bottom-color: #334155;
}

body.dark-theme .logo-text-primary {
  color: #ffffff;
}

body.dark-theme .theme-toggle-btn {
  background-color: #1e293b;
  color: #38bdf8;
  border-color: #0066ff;
  box-shadow: 0 2px 8px rgba(0, 102, 255, 0.25);
}

body.dark-theme .theme-toggle-btn:hover {
  background-color: #0066ff;
  color: #ffffff;
  border-color: #0052cc;
  box-shadow: 0 4px 14px rgba(0, 102, 255, 0.5);
}

/* Dark Mode Upload Cards & Settings Cards & Result Card */
body.dark-theme .compact-card,
body.dark-theme .single-card,
body.dark-theme .dropzone,
body.dark-theme .workspace-section,
body.dark-theme .result-section {
  background-color: #0f172a;
  border: 3px dashed #0066ff;
  box-shadow: 0 10px 32px rgba(0, 102, 255, 0.25);
}

body.dark-theme .compact-card:hover,
body.dark-theme .single-card:hover,
body.dark-theme .dropzone:hover,
body.dark-theme .workspace-section:hover,
body.dark-theme .result-section:hover {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f2b4a 100%);
  border-color: #38bdf8;
  box-shadow: 0 18px 44px rgba(56, 189, 248, 0.3), 0 0 0 4px rgba(56, 189, 248, 0.16);
}

body.dark-theme .compact-icon-glow {
  background: linear-gradient(135deg, #0066ff 0%, #0041b3 100%);
  color: #ffffff;
}

body.dark-theme .compact-drop-title,
body.dark-theme .drop-title,
body.dark-theme .features-title {
  color: #ffffff;
}

body.dark-theme .compact-subtext,
body.dark-theme .or-text,
body.dark-theme .feature-text {
  color: #e2e8f0;
  font-weight: 700;
}

body.dark-theme .badge-pill {
  background-color: #1e293b;
  border-color: #475569;
  color: #ffffff;
  font-weight: 800;
}

body.dark-theme .badge-pill:hover {
  background-color: #0066ff;
  color: #ffffff;
  border-color: #38bdf8;
  box-shadow: 0 6px 16px rgba(0, 102, 255, 0.5);
}

body.dark-theme .features-card {
  background-color: #0f172a;
  border-color: #334155;
}

body.dark-theme .compact-header-tag::before {
  background: #334155;
}

body.dark-theme .compact-header-tag span {
  background: #0f172a;
  color: #38bdf8;
}

body.dark-theme .compact-card:hover .compact-header-tag span {
  background: #162238;
  color: #38bdf8;
}

/* Dark Mode Settings & Result Cards */
body.dark-theme .workspace-section,
body.dark-theme .result-section {
  background-color: #0f172a;
  color: #ffffff;
}

body.dark-theme .result-stats-strip {
  background: #162238;
  border-color: #334155;
  color: #ffffff;
}

body.dark-theme .strip-icon {
  stroke: #38bdf8;
}

body.dark-theme .strip-icon-green {
  stroke: #34d399;
}

body.dark-theme .stat-pill strong {
  color: #38bdf8;
}

body.dark-theme .stat-divider {
  background: #334155;
}

body.dark-theme .stat-saved-badge {
  background: #065f46;
  color: #34d399;
}

body.dark-theme .format-toggle-container {
  border-color: #334155;
  background: #1e293b;
}

body.dark-theme .format-tab-btn {
  background: #1e293b;
  color: #ffffff;
}

body.dark-theme .format-tab-btn .tab-title {
  color: #ffffff;
}

body.dark-theme .format-tab-btn .tab-sub {
  color: #cbd5e1;
  font-weight: 700;
}

body.dark-theme .format-tab-btn + .format-tab-btn {
  border-left-color: #334155;
}

/* Active Golden Tab in Dark Mode */
body.dark-theme .format-tab-btn.active {
  background-color: #ffb700;
  color: #000000;
}

body.dark-theme .format-tab-btn.active .tab-title,
body.dark-theme .format-tab-btn.active .tab-sub {
  color: #000000;
  font-weight: 900;
}

/* Dark Mode Summary Box */
body.dark-theme .selected-summary-box {
  background-color: #162238;
  border-color: #334155;
}

body.dark-theme .summary-item {
  color: #ffffff;
  font-weight: 800;
}

body.dark-theme .summary-svg {
  color: #38bdf8;
}

body.dark-theme .summary-text {
  color: #ffffff;
}

body.dark-theme .summary-text strong {
  color: #38bdf8;
  font-weight: 900;
}

body.dark-theme .summary-divider {
  background-color: #334155;
}

/* Dark Mode Single Line Controls */
body.dark-theme .single-line-controls {
  background-color: #162238;
  border-color: #334155;
}

body.dark-theme .mini-mode-toggle {
  background-color: #334155;
}

body.dark-theme .mini-tab-btn {
  color: #f8fafc;
  font-weight: 800;
}

body.dark-theme .mini-tab-btn.active {
  background: #0066ff;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 102, 255, 0.4);
}

body.dark-theme .row-label {
  color: #ffffff;
  font-weight: 900;
}

body.dark-theme .mini-size-input,
body.dark-theme .mini-unit-select {
  background-color: #1e293b;
  color: #ffffff;
  border-color: #475569;
  font-weight: 800;
}

/* HIGH-VISIBILITY DARK MODE SECONDARY BUTTONS (+ Add Images & Clear All) */
body.dark-theme .btn-add-images {
  background-color: #065f46;
  border: 1.5px solid #10b981;
  color: #34d399; /* Vibrant mint green text - 100% visible! */
}

body.dark-theme .btn-add-images:hover {
  background-color: #10b981;
  border-color: #34d399;
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.4);
}

body.dark-theme .btn-clear-all {
  background-color: #991b1b;
  border: 1.5px solid #f87171;
  color: #ffffff; /* PURE WHITE TEXT on Red - 100% crystal visible! */
}

body.dark-theme .btn-clear-all:hover {
  background-color: #ef4444;
  border-color: #fca5a5;
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4);
}

/* Dark Mode Result Page */
body.dark-theme .result-title {
  color: #ffffff;
}

body.dark-theme .result-subtext {
  color: #e2e8f0;
  font-weight: 700;
}

body.dark-theme .result-header {
  border-bottom-color: #334155;
}

body.dark-theme .batch-list::-webkit-scrollbar-track {
  background: #1e293b;
}

body.dark-theme .batch-list::-webkit-scrollbar-thumb {
  background: #475569;
}

body.dark-theme .batch-card {
  background-color: #162238;
  border-color: #334155;
}

body.dark-theme .item-name {
  color: #ffffff;
}

body.dark-theme .stat-orig {
  color: #94a3b8;
}

body.dark-theme .stat-arrow {
  color: #38bdf8;
}

body.dark-theme .stat-comp {
  color: #ffffff;
}

body.dark-theme .badge-saved {
  background-color: #065f46;
  color: #34d399;
}

body.dark-theme .btn-remove-single {
  background: #450a0a;
  border-color: #991b1b;
  color: #fca5a5;
}

body.dark-theme .btn-remove-single:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #f87171;
}

/* ==========================================================================
   TABLET SPECIFIC RESPONSIVE SCALING & VISIBILITY (481px to 820px)
   ========================================================================== */
@media (min-width: 481px) and (max-width: 820px) {
  .header {
    padding: 12px 24px;
  }

  .compact-header-container {
    max-width: 520px;
    width: 100%;
  }

  .main-content {
    padding: 24px 20px 50px;
  }

  /* Centered Proportional Card Width on Tablet Screens */
  .compact-card-wrapper,
  .workspace-section,
  .result-section {
    max-width: 520px;
    width: 100%;
    margin: 0 auto;
  }

  /* Step 1: Upload Card Tablet Scaling & Visibility */
  .compact-card {
    padding: 30px 24px;
    border-radius: 24px;
  }

  .compact-drop-title {
    font-size: 22px;
    font-weight: 800;
  }

  .compact-subtext {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 20px;
  }

  .modern-choose-btn {
    padding: 12px 30px;
    font-size: 15px;
  }

  .compact-badges-grid {
    gap: 9px;
    margin-top: 4px;
  }

  .badge-pill {
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 800;
  }

  .pill-icon {
    font-size: 14px;
  }

  /* Step 2: Compression Settings Card Tablet Scaling */
  .workspace-section {
    padding: 28px 24px;
    border-radius: 24px;
  }

  .format-toggle-container {
    height: 52px;
  }

  .format-tab-btn .tab-title {
    font-size: 15.5px;
    font-weight: 900;
  }

  .format-tab-btn .tab-sub {
    font-size: 12px;
    font-weight: 700;
  }

  .selected-summary-box {
    height: 48px;
    padding: 4px 12px;
  }

  .summary-item {
    font-size: 14px;
    font-weight: 800;
  }

  .single-line-controls {
    height: 50px;
    padding: 6px 14px;
  }

  .mini-tab-btn {
    font-size: 12.5px;
    padding: 4px 11px;
  }

  .mini-slider {
    width: 110px;
  }

  .mini-size-input {
    width: 70px;
    font-size: 13px;
  }

  .mini-unit-select {
    font-size: 13px;
  }

  .btn-start-action {
    height: 50px;
    font-size: 16.5px;
  }

  .btn-add-images,
  .btn-clear-all {
    height: 44px;
    font-size: 14px;
  }

  /* Step 3: Result Card Tablet Scaling */
  .result-section {
    padding: 20px 22px;
    border-radius: 24px;
  }

  .result-title {
    font-size: 21px;
  }

  .result-subtext {
    font-size: 13px;
  }

  .result-stats-strip {
    height: 34px;
    padding: 0 12px;
    font-size: 12.5px;
  }

  .batch-card {
    height: 70px;
    padding: 10px 14px;
  }

  .item-preview {
    width: 48px;
    height: 48px;
  }

  .item-name {
    font-size: 14px;
    max-width: 220px;
  }

  .item-stats {
    font-size: 12.5px;
  }

  .btn-remove-single {
    width: 32px;
    height: 36px;
    font-size: 14px;
  }

  .btn-download-single {
    width: 36px;
    height: 36px;
  }

  .btn-download-all,
  .btn-secondary {
    height: 44px;
    font-size: 14.5px;
  }
}

/* ==========================================================================
   SMARTPHONE MOBILE DEVICES RESPONSIVE QUERY (MAX WIDTH: 480PX)
   ========================================================================== */
@media (max-width: 480px) {
  .header {
    padding: 8px 12px;
  }

  .logo-title-group {
    font-size: 19px;
  }

  .logo-icon-box {
    width: 32px;
    height: 32px;
  }

  .logo-icon-box svg {
    width: 20px;
    height: 20px;
  }

  .compact-card {
    padding: 20px 14px;
  }

  .compact-drop-title {
    font-size: 19px;
  }

  .compact-subtext {
    font-size: 12.5px;
    margin-bottom: 14px;
  }

  .modern-choose-btn {
    padding: 10px 22px;
    font-size: 13.5px;
  }

  .compact-badges-grid {
    gap: 6px;
  }

  .badge-pill {
    padding: 5px 10px;
    font-size: 11.5px;
  }

  .pill-icon {
    font-size: 12px;
  }

  /* Step 2 Settings Card on Mobile */
  .workspace-section {
    padding: 18px 14px;
  }

  .format-toggle-container {
    height: 46px;
  }

  .format-tab-btn .tab-title {
    font-size: 13.5px;
  }

  .format-tab-btn .tab-sub {
    font-size: 10.5px;
  }

  .selected-summary-box {
    height: auto;
    min-height: 44px;
    padding: 6px 10px;
  }

  .summary-item {
    font-size: 12.5px;
  }

  .single-line-controls {
    height: auto;
    min-height: 46px;
    padding: 6px 10px;
    gap: 6px;
  }

  .mini-mode-toggle {
    padding: 2px;
  }

  .mini-tab-btn {
    font-size: 11px;
    padding: 3px 8px;
  }

  .mini-slider {
    width: 85px;
  }

  .mini-size-input {
    width: 58px;
    padding: 3px 6px;
    font-size: 11.5px;
  }

  .mini-unit-select {
    padding: 3px 4px;
    font-size: 11.5px;
  }

  .btn-start-action {
    height: 44px;
    font-size: 15px;
  }

  .workspace-actions {
    gap: 8px;
  }

  .btn-add-images,
  .btn-clear-all {
    height: 38px;
    font-size: 12.5px;
    padding: 0 8px;
  }

  /* Step 3 Result Card on Mobile (<480px) */
  .result-section {
    padding: 16px 12px;
    border-radius: 20px;
    gap: 10px;
  }

  .result-header {
    padding-bottom: 4px;
  }

  .result-title {
    font-size: 18px;
    gap: 5px;
  }

  .pop-emoji {
    font-size: 19px;
  }

  .result-subtext {
    font-size: 11.5px;
  }

  /* Ultra-Compact Mobile Stats Strip - Zero Overflow */
  .result-stats-strip {
    height: 32px;
    padding: 0 6px;
    font-size: 10.5px;
    gap: 2px;
    justify-content: space-between;
    overflow: hidden;
  }

  .stat-pill {
    gap: 3px;
    font-size: 10.5px;
    white-space: nowrap;
  }

  .stat-label-text {
    display: none; /* Hide 'Orig:' and 'Comp:' labels on mobile to save 28px width! */
  }

  .strip-icon,
  .strip-icon-green {
    width: 12px;
    height: 12px;
  }

  .stat-divider {
    height: 45%;
  }

  .stat-saved-badge {
    font-size: 9.5px;
    padding: 1px 4px;
    border-radius: 5px;
    margin-left: 1px;
  }

  /* Clean Mobile Batch List & Zero Action Button Clipping */
  .batch-list {
    max-height: 220px;
    gap: 8px;
    margin-bottom: 2px;
  }

  .batch-card {
    height: 64px;
    padding: 6px 8px;
    gap: 8px;
    border-radius: 12px;
  }

  .item-preview {
    width: 42px;
    height: 42px;
    border-radius: 8px;
  }

  .item-info {
    gap: 2px;
    min-width: 0;
  }

  .item-name {
    font-size: 12.5px;
    font-weight: 800;
    max-width: 120px;
  }

  .item-stats {
    font-size: 11px;
    gap: 3px;
  }

  .stat-arrow {
    font-size: 9.5px;
  }

  .badge-saved {
    font-size: 9.5px;
    padding: 1px 4px;
  }

  .item-actions-group {
    gap: 6px;
  }

  .btn-remove-single {
    width: 28px;
    height: 32px;
    font-size: 13px;
  }

  .btn-download-single {
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }

  .btn-download-single svg {
    width: 14px;
    height: 14px;
  }

  .result-actions {
    display: flex;
    gap: 8px;
    margin-top: 2px;
    flex-shrink: 0;
  }

  .btn-download-all {
    flex: 1.2;
    height: 42px;
    font-size: 12.5px;
    font-weight: 900;
    padding: 0 6px;
    border-radius: 12px;
    white-space: nowrap;
  }

  .btn-secondary {
    flex: 1;
    height: 42px;
    font-size: 11.5px;
    font-weight: 800;
    padding: 0 6px;
    border-radius: 12px;
    white-space: nowrap;
  }
}
