:root {
  /* Pödüfü.online Soft Lavanta & Derin İndigo Paleti */
  --bg-primary: #F8F7FA;       /* Açık Sis / Lavanta Beji */
  --bg-secondary: #FFFFFF;     /* Saf Beyaz */
  --bg-card: #FFFFFF;          /* Odak kutuları */
  --border-color: #E4E4E7;     /* Nötr Gri */
  --text-primary: #18181B;     /* Koyu Mürekkep */
  --text-secondary: #71717A;   /* İkincil metin */
  
  --brand-primary: #5B5CE5;     /* Canlı Periwinkle / İndigo (CTA) */
  --brand-hover: #4B4BD6;
  --brand-light: #EEEBFF;       /* Şeker Lavanta (Hover / Highlight) */
  --brand-gradient: linear-gradient(135deg, #5B5CE5, #7C7EF8);

  --accent-red: #EF4444;
  --accent-green: #10B981;
  --accent-amber: #F59E0B;
  --accent-blue: #3B82F6;

  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Plus Jakarta Sans", Inter, sans-serif;
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --shadow-card: 0 2px 8px -2px rgba(24, 24, 27, 0.05), 0 4px 16px -4px rgba(24, 24, 27, 0.06);
  --shadow-hover: 0 12px 28px -6px rgba(91, 92, 229, 0.16), 0 4px 12px -2px rgba(24, 24, 27, 0.05);
  --transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
  --bg-primary: #0F0F17;
  --bg-secondary: #171723;
  --bg-card: #171723;
  --border-color: #272738;
  --text-primary: #F4F4F5;
  --text-secondary: #A1A1AA;
  --brand-primary: #6E70FF;
  --brand-hover: #5B5CE5;
  --brand-light: rgba(110, 112, 255, 0.15);
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.35);
  --shadow-hover: 0 12px 28px rgba(91, 92, 229, 0.25);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.5;
  transition: background-color 0.25s ease, color 0.25s ease;
  -webkit-font-smoothing: antialiased;
}

/* Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(248, 247, 250, 0.92);
  border-bottom: 1px solid var(--border-color);
  padding: 0.65rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

[data-theme="dark"] .app-header {
  background: rgba(15, 15, 23, 0.92);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: inherit;
}

.brand-icon {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
}

.brand:hover .brand-icon {
  transform: translateY(-1px) scale(1.04);
}

.brand-text {
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: baseline;
  gap: 0.15rem;
}

.brand-domain {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-primary);
  background: var(--brand-light);
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.theme-toggle-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.theme-toggle-btn:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

/* Container */
.main-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 1.25rem 1.25rem 2.5rem;
  flex: 1;
  width: 100%;
}

/* Hero Section */
.hero {
  text-align: center;
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: 2.1rem;
  font-weight: 850;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 0.35rem;
}

.hero h1 span {
  color: var(--brand-primary);
}

.hero p {
  color: var(--text-secondary);
  font-size: 0.96rem;
  max-width: 500px;
  margin: 0 auto 1.1rem;
}

/* Hero Dropzone (Larger, more prominent & inviting) */
.hero-dropzone {
  max-width: 740px;
  margin: 0 auto 1.5rem;
  border: 2px dashed rgba(91, 92, 229, 0.45);
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: 2.2rem 2.6rem;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-card);
}

.hero-dropzone:hover, .hero-dropzone.dragover {
  border-color: var(--brand-primary);
  background: var(--brand-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.hero-dropzone-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}

.hero-dropzone-icon {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: var(--brand-light);
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
}

.hero-dropzone:hover .hero-dropzone-icon {
  background: var(--brand-primary);
  color: white;
  transform: scale(1.06);
}

.hero-dropzone-text {
  text-align: left;
}

.hero-dropzone-text h3 {
  font-size: 1.25rem;
  font-weight: 750;
  margin-bottom: 0.25rem;
  letter-spacing: -0.01em;
}

.hero-dropzone-text p {
  color: var(--text-secondary);
  font-size: 0.88rem;
  margin: 0 0 0.4rem;
}

.dropzone-browse-text {
  color: var(--brand-primary);
  font-weight: 600;
  text-decoration: underline;
}

.supported-formats-pills {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.supported-formats-pills span {
  font-size: 0.72rem;
  font-weight: 700;
  background: var(--brand-light);
  color: var(--brand-primary);
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
}

/* Search Bar */
.search-wrapper {
  max-width: 440px;
  margin: 0 auto 0.9rem;
}

.search-input {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.65rem 1.15rem;
  border-radius: 999px;
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
}

.search-input:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(91, 92, 229, 0.15);
}

/* 4 Category Filters */
.filter-bar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.5rem;
}

.filter-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.45rem 1.15rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.filter-btn:hover {
  color: var(--brand-primary);
  border-color: var(--brand-primary);
  background: var(--brand-light);
}

.filter-btn.active {
  background: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
  box-shadow: 0 3px 10px rgba(91, 92, 229, 0.35);
}

/* Tools Grid */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}

.tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  text-decoration: none;
  color: inherit;
}

.tool-card:hover {
  transform: translateY(-3px);
  border-color: var(--brand-primary);
  box-shadow: var(--shadow-hover);
}

/* Desktop Drag-Target state on individual card */
.tool-card.drag-target {
  border-color: var(--brand-primary) !important;
  background: var(--brand-light) !important;
  transform: scale(1.04) translateY(-3px) !important;
  box-shadow: 0 0 24px rgba(91, 92, 229, 0.4) !important;
}

.tool-card.drag-target::after {
  content: 'Buraya Bırak!';
  position: absolute;
  inset: 0;
  background: rgba(248, 247, 250, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--brand-primary);
  backdrop-filter: blur(2px);
  z-index: 10;
}

[data-theme="dark"] .tool-card.drag-target::after {
  background: rgba(15, 15, 23, 0.92);
}

.tool-icon-wrapper {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: var(--brand-light);
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.9rem;
  transition: var(--transition);
}

.tool-card:hover .tool-icon-wrapper {
  background: var(--brand-primary);
  color: white;
}

.tool-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
  letter-spacing: -0.01em;
}

.tool-card p {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.4;
  flex: 1;
}

.tool-tag {
  align-self: flex-start;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.18rem 0.5rem;
  border-radius: 4px;
  margin-top: 0.9rem;
  background: var(--bg-primary);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

/* Quick Action Buttons in Picker */
.quick-action-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: left;
}

.quick-action-btn:hover {
  border-color: var(--brand-primary);
  background: var(--brand-light);
  color: var(--brand-primary);
}

/* Modal / Workspace Overlay */
.workspace-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(24, 24, 27, 0.55);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  overflow-y: auto;
}

.workspace-overlay.active {
  display: flex;
}

.workspace-modal {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 840px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.25);
  animation: modalEnter 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalEnter {
  from { opacity: 0; transform: scale(0.96) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.workspace-header {
  padding: 1.1rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.workspace-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.workspace-title h2 {
  font-size: 1.25rem;
  font-weight: 700;
}

.modal-icon-accent {
  color: var(--brand-primary);
  display: flex;
}

.close-modal-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.close-modal-btn:hover {
  background: var(--bg-primary);
  color: var(--text-primary);
}

.workspace-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

/* Upload Dropzone (Inside tool modal) */
.dropzone {
  border: 2px dashed rgba(91, 92, 229, 0.4);
  border-radius: var(--radius-md);
  padding: 2.25rem 1.5rem;
  text-align: center;
  cursor: pointer;
  background: var(--bg-primary);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
}

.dropzone:hover, .dropzone.dragover {
  border-color: var(--brand-primary);
  background: var(--brand-light);
}

.dropzone-icon {
  width: 52px;
  height: 52px;
  background: var(--brand-light);
  color: var(--brand-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dropzone h4 {
  font-size: 1.1rem;
  font-weight: 700;
}

.dropzone p {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.browse-btn {
  background: var(--brand-primary);
  color: white;
  border: none;
  padding: 0.55rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(91, 92, 229, 0.3);
  transition: var(--transition);
}

.browse-btn:hover {
  background: var(--brand-hover);
}

/* File List */
.file-list {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.1rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.selected-file-card {
  background: var(--bg-primary);
  border: 1.5px solid var(--brand-primary);
  box-shadow: 0 4px 16px rgba(91, 92, 229, 0.12);
  animation: fileCardPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes fileCardPop {
  0% { transform: scale(0.97); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.file-info {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  overflow: hidden;
  flex: 1;
}

.file-item-icon {
  width: 42px;
  height: 42px;
  background: rgba(91, 92, 229, 0.1);
  color: var(--brand-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.file-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  overflow: hidden;
}

.file-name-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.file-name {
  font-weight: 700;
  font-size: 0.92rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
  color: var(--text-primary);
}

.file-badge-success {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.14);
  color: #16a34a;
  display: inline-flex;
  align-items: center;
  letter-spacing: 0.02em;
}

[data-theme="dark"] .file-badge-success {
  background: rgba(34, 197, 94, 0.25);
  color: #4ade80;
}

.file-size {
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 500;
}

.file-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.btn-change-file {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.42rem 0.8rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
}

.btn-change-file:hover {
  background: rgba(91, 92, 229, 0.1);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.file-index-badge {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-primary);
  background: rgba(91, 92, 229, 0.12);
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  flex-shrink: 0;
}

.btn-icon-sm {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  width: 30px;
  height: 30px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  transition: var(--transition);
}

.btn-icon-sm:hover {
  background: rgba(91, 92, 229, 0.12);
  color: var(--brand-primary);
  border-color: var(--brand-primary);
}

.remove-file-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0.4rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.remove-file-btn:hover {
  background: rgba(239, 68, 68, 0.12);
  color: var(--accent-red);
}

/* Interactive Page Grid */
.page-grid-container {
  margin-top: 1.25rem;
}

.page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.75rem;
  max-height: 350px;
  overflow-y: auto;
  padding: 0.5rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
}

.page-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.45rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  transition: var(--transition);
  user-select: none;
}

.page-card:hover {
  border-color: var(--brand-primary);
  box-shadow: 0 2px 8px rgba(91, 92, 229, 0.2);
}

.page-thumb {
  width: 100%;
  aspect-ratio: 1 / 1.414;
  object-fit: contain;
  background: white;
  border-radius: 3px;
  margin-bottom: 0.35rem;
  transition: transform 0.2s ease;
}

.page-number-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.page-actions {
  display: flex;
  gap: 0.25rem;
  margin-top: 0.35rem;
}

.page-action-btn {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  width: 24px;
  height: 24px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.page-action-btn:hover {
  color: var(--brand-primary);
  border-color: var(--brand-primary);
}

.page-action-btn.btn-delete:hover {
  border-color: var(--accent-red);
  color: var(--accent-red);
}

/* Options Box */
.tool-options {
  margin-top: 1.25rem;
  padding: 1.15rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
}

.form-control {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.55rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(91, 92, 229, 0.2);
}

.btn-group {
  display: flex;
  gap: 0.45rem;
}

.btn-option {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.55rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: var(--transition);
}

.btn-option.active {
  background: var(--brand-light);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

/* Modal Footer */
.workspace-footer {
  padding: 1.1rem 1.5rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-secondary);
}

.action-submit-btn {
  background: var(--brand-primary);
  color: white;
  border: none;
  padding: 0.7rem 1.8rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 3px 12px rgba(91, 92, 229, 0.35);
  transition: var(--transition);
}

.action-submit-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

.action-submit-btn:not(:disabled):hover {
  background: var(--brand-hover);
  transform: translateY(-1px);
}

/* Result / Download Screen */
.result-screen {
  text-align: center;
  padding: 2rem 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.success-icon-badge {
  width: 64px;
  height: 64px;
  background: rgba(16, 185, 129, 0.12);
  border: 2px solid rgba(16, 185, 129, 0.35);
  color: #10B981;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.download-btn {
  background: #10B981;
  color: white;
  border: none;
  padding: 0.75rem 2rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
  transition: var(--transition);
}

.download-btn:hover {
  background: #059669;
  transform: translateY(-1px);
}

.reset-tool-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.reset-tool-btn:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
}

/* Toast */
.toast-container {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.toast {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.75rem 1.15rem;
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  font-size: 0.88rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.toast.error {
  border-color: var(--accent-red);
  color: var(--accent-red);
}

.toast.success {
  border-color: var(--accent-green);
  color: var(--accent-green);
}

/* Footer & Legal (Single Clean Strip) */
.app-footer {
  border-top: 1px solid var(--border-color);
  padding: 0.85rem 1.5rem;
  color: var(--text-secondary);
  font-size: 0.82rem;
  margin-top: auto;
  background: var(--bg-secondary);
  width: 100%;
}

.footer-strip {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.footer-brand-name {
  font-weight: 700;
  color: var(--text-primary);
}

.footer-community {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.footer-powered {
  color: var(--brand-primary);
  font-weight: 600;
}

.footer-links {
  display: flex;
  gap: 0.65rem;
  align-items: center;
  flex-wrap: wrap;
  font-size: 0.82rem;
  font-weight: 500;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--brand-primary);
  text-decoration: underline;
}

.footer-dot {
  color: var(--border-color);
  font-size: 0.8rem;
}

/* Spinner */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 0.8s linear infinite;
}

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

/* Real-time Progress Bar */
.progress-container {
  margin-top: 1.25rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.9rem 1.15rem;
  animation: fadeIn 0.3s ease;
}

.progress-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.progress-status-label {
  color: var(--text-primary);
}

.progress-percentage-label {
  color: var(--brand-primary);
  font-weight: 700;
}

.progress-bar-track {
  width: 100%;
  height: 8px;
  background: var(--border-color);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand-primary), #7A7BF6);
  border-radius: 4px;
  width: 0%;
  transition: width 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-bar-fill.processing {
  width: 100% !important;
  background: linear-gradient(90deg, var(--brand-primary), #A5A6F6, var(--brand-primary));
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite linear;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.minimize-task-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.65rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.minimize-task-btn:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
  background: var(--brand-light);
}

/* Floating Queue Dock */
.queue-dock {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 320px;
  max-width: calc(100vw - 2rem);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
  z-index: 999;
  overflow: hidden;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.queue-dock-header {
  padding: 0.75rem 1rem;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.queue-dock-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-primary);
  box-shadow: 0 0 0 0 rgba(91, 92, 229, 0.7);
  animation: pulseDot 1.5s infinite;
}

@keyframes pulseDot {
  0% { box-shadow: 0 0 0 0 rgba(91, 92, 229, 0.7); }
  70% { box-shadow: 0 0 0 6px rgba(91, 92, 229, 0); }
  100% { box-shadow: 0 0 0 0 rgba(91, 92, 229, 0); }
}

.queue-toggle-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 0.9rem;
  padding: 0.2rem;
}

.queue-dock-items {
  max-height: 220px;
  overflow-y: auto;
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.queue-item {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  font-size: 0.82rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.queue-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.queue-item-name {
  font-weight: 600;
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-item-status {
  font-size: 0.76rem;
  color: var(--brand-primary);
  font-weight: 600;
}

.queue-item-progress-track {
  width: 100%;
  height: 5px;
  background: var(--border-color);
  border-radius: 3px;
  overflow: hidden;
}

.queue-item-progress-fill {
  height: 100%;
  background: var(--brand-primary);
  width: 0%;
  transition: width 0.2s ease;
}

/* Google AdSense Slots */
.ad-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ad-slot-top {
  max-width: 970px;
  min-height: 10px;
  margin: 0.5rem auto;
}

.ad-slot-bottom {
  max-width: 970px;
  min-height: 10px;
  margin: 1.25rem auto 0.75rem;
}

.ad-slot-result {
  max-width: 480px;
  min-height: 10px;
  margin: 0.75rem auto;
}

/* Mobile Responsiveness Optimizations */
@media (max-width: 768px) {
  .app-header { padding: 0.5rem 1rem; }
  .main-container { padding: 0.85rem 0.85rem 2rem; }
  .hero { margin-bottom: 1.1rem; }
  .hero h1 { font-size: 1.55rem; margin-bottom: 0.25rem; }
  .hero p { font-size: 0.88rem; margin-bottom: 0.85rem; }
  
  .hero-dropzone { padding: 1.25rem 1rem; margin-bottom: 1rem; }
  .hero-dropzone-content { gap: 0.9rem; }
  .hero-dropzone-icon { width: 44px; height: 44px; }
  .hero-dropzone-text h3 { font-size: 1rem; }
  .hero-dropzone-text p { font-size: 0.82rem; margin-bottom: 0.35rem; }
  
  .search-wrapper { margin-bottom: 0.75rem; }
  .filter-bar { gap: 0.35rem; margin-bottom: 1rem; }
  .filter-btn { padding: 0.38rem 0.85rem; font-size: 0.82rem; }
  .tools-grid { grid-template-columns: 1fr; gap: 0.75rem; }
  .tool-card { padding: 1.1rem; }
  .workspace-modal { max-width: 100%; height: 100vh; border-radius: 0; }
  .footer-strip {
    flex-direction: column;
    justify-content: center;
    text-align: center;
    gap: 0.5rem;
  }
  .footer-left, .footer-links {
    justify-content: center;
    font-size: 0.78rem;
  }
}

/* ============================================================
   Language Picker (i18n)
   ============================================================ */
.lang-picker {
  position: relative;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.42rem 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.lang-btn:hover {
  border-color: var(--brand-primary);
  background: var(--bg-hover);
}

.lang-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
  padding: 0.35rem;
  min-width: 145px;
  display: none;
  flex-direction: column;
  gap: 0.2rem;
  z-index: 1000;
}

.lang-dropdown.active {
  display: flex;
}

.lang-opt {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.7rem;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  text-align: left;
  transition: all var(--transition-fast);
}

.lang-opt:hover {
  background: var(--bg-hover);
  color: var(--brand-primary);
}

.lang-opt.active {
  background: var(--brand-primary-light);
  color: var(--brand-primary);
  font-weight: 700;
}

/* ============================================================
   Organic SEO Content Section
   ============================================================ */
.seo-section {
  max-width: 900px;
  margin: 3.5rem auto 1.5rem auto;
  padding: 2.2rem 2.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.seo-heading {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.seo-p {
  font-size: 0.93rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 0.9rem;
}

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

/* ============================================================
   FAQ Accordion Section (Schema.org Ready)
   ============================================================ */
.faq-section {
  max-width: 900px;
  margin: 1.5rem auto 3.5rem auto;
}

.faq-heading {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 1.5rem;
}

.faq-grid {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color var(--transition-fast);
}

.faq-item:hover {
  border-color: var(--brand-primary);
}

.faq-question {
  width: 100%;
  padding: 1.1rem 1.3rem;
  background: transparent;
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
}

.faq-chevron {
  transition: transform 0.25s ease;
  flex-shrink: 0;
  color: var(--text-secondary);
}

.faq-item.active .faq-chevron {
  transform: rotate(180deg);
  color: var(--brand-primary);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-secondary);
  padding: 0 1.3rem;
}

.faq-item.active .faq-answer {
  max-height: 250px;
  padding: 0 1.3rem 1.15rem 1.3rem;
}

@media (max-width: 768px) {
  .seo-section {
    padding: 1.5rem 1.25rem;
    margin: 2rem auto 1rem auto;
  }
  .seo-heading { font-size: 1.15rem; }
  .seo-p { font-size: 0.88rem; }
  .faq-section { margin-bottom: 2rem; }
  .faq-heading { font-size: 1.15rem; }
  .faq-question { padding: 0.95rem 1.1rem; font-size: 0.88rem; }
}
