/* Shared base styles (inlined so pdf/ is 100% self-contained) */
:root {
  --brand-primary: #059669;
  --brand-primary-hover: #047857;
  --brand-secondary: #0ea5e9;
  --brand-gradient: linear-gradient(135deg, #059669 0%, #0d9488 55%, #0284c7 100%);
  --brand-soft: #ecfdf5;
  --brand-border: #a7f3d0;
  --surface-bg: #f8fafc;
  --surface-card: #ffffff;
  --text-main: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 9999px;
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 1px 3px rgba(15, 23, 42, 0.03);
  --shadow-float: 0 20px 45px -12px rgba(15, 23, 42, 0.12);
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
* { box-sizing: border-box; }
body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--surface-bg);
  background-image: radial-gradient(at 0% 0%, rgba(16, 185, 129, 0.08) 0px, transparent 50%), radial-gradient(at 100% 0%, rgba(14, 165, 233, 0.08) 0px, transparent 50%);
  background-repeat: no-repeat;
  color: var(--text-main);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand-primary); text-decoration: none; transition: all var(--transition); }
a:hover { color: var(--brand-primary-hover); }
.gradient-text { background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* Navbar */
.navbar-wrapper { position: sticky; top: 12px; z-index: 1030; padding: 0 1rem; margin-bottom: 1rem; }
.navbar {
  max-width: 1180px; margin: 0 auto; background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px) saturate(180%); -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(226, 232, 240, 0.9); border-radius: 18px; padding: 0.6rem 1.25rem;
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.05);
}
.navbar-brand { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.03em; color: var(--text-main) !important; display: flex; align-items: center; gap: 0.6rem; }
.brand-logo-box { width: 36px; height: 36px; border-radius: 10px; background: var(--brand-gradient); display: inline-flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 4px 12px rgba(5, 150, 105, 0.3); }
.navbar .nav-link { font-weight: 600; font-size: 0.86rem; color: var(--text-secondary) !important; padding: 0.45rem 0.72rem !important; border-radius: var(--radius-sm); transition: all var(--transition); white-space: nowrap; }
.navbar .nav-link:hover, .navbar .nav-link.active-tool { background: var(--brand-soft); color: var(--brand-primary) !important; }
.nav-cta-pill { background: var(--text-main) !important; color: #fff !important; border-radius: var(--radius-pill) !important; padding: 0.45rem 1.05rem !important; margin-left: 0.35rem; }
.nav-cta-pill:hover { background: var(--brand-primary) !important; color: #fff !important; }
.lang-select-nav { font-weight: 600; border-radius: 8px; cursor: pointer; background-color: #f8f9fa; border: 1px solid var(--border-color); font-size: 0.84rem; color: var(--text-main); }

/* Hero & Studio Shell */
.workspace-section { padding: 1.5rem 1rem 2rem; }
.hero-head { text-align: center; max-width: 780px; margin: 0 auto 2rem; }
.trust-pill-bar { display: inline-flex; align-items: center; gap: 0.5rem; background: #fff; border: 1px solid var(--border-color); padding: 0.35rem 0.9rem; border-radius: var(--radius-pill); font-size: 0.8rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 1rem; box-shadow: var(--shadow-xs); }
.trust-pill-bar .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand-primary); box-shadow: 0 0 0 4px rgba(5, 150, 105, 0.15); }
.hero-head h1 { font-size: clamp(2.1rem, 4.5vw, 3rem); font-weight: 800; letter-spacing: -0.04em; line-height: 1.15; margin-bottom: 0.75rem; color: var(--text-main); }
.hero-head p { font-size: 1.05rem; color: var(--text-secondary); margin-bottom: 0; }
.studio-shell { max-width: 1140px; margin: 0 auto; background: var(--surface-card); border: 1px solid var(--border-color); border-radius: var(--radius-lg); box-shadow: var(--shadow-float); padding: 1.75rem; position: relative; }

/* Upload Dropzone */
.upload-container { border: 2px dashed #cbd5e1; border-radius: 20px; background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%); padding: 3.1rem 1.5rem; text-align: center; cursor: pointer; transition: all var(--transition); position: relative; }
.upload-container:hover, .upload-container.dragover { border-color: var(--brand-primary); background: #f0fdf4; transform: translateY(-2px); box-shadow: 0 12px 30px -10px rgba(5, 150, 105, 0.15); }
.upload-icon-ring { width: 72px; height: 72px; border-radius: 22px; background: var(--brand-soft); border: 1px solid var(--brand-border); display: flex; align-items: center; justify-content: center; margin: 0 auto 1.15rem; color: var(--brand-primary); transition: transform var(--transition); }
.upload-container:hover .upload-icon-ring { transform: scale(1.06) rotate(-3deg); }
.upload-container h3, .upload-container .upload-title { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 0.3rem; }
.spec-badges { display: flex; justify-content: center; gap: 0.5rem; flex-wrap: wrap; margin-top: 1.25rem; }
.spec-badge { font-size: 0.76rem; font-weight: 600; color: var(--text-muted); background: #f1f5f9; padding: 0.3rem 0.75rem; border-radius: var(--radius-pill); }

/* Buttons */
.btn-brand { display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem; padding: 0.8rem 1.85rem; font-weight: 700; font-size: 0.95rem; color: #fff; border: none; border-radius: 14px; background: var(--brand-gradient); box-shadow: 0 10px 20px -8px rgba(5, 150, 105, 0.5); transition: all var(--transition); cursor: pointer; }
.btn-brand:hover { transform: translateY(-2px); box-shadow: 0 14px 26px -8px rgba(5, 150, 105, 0.65); color: #fff; filter: brightness(1.03); }
.btn-brand:disabled { opacity: 0.7; cursor: wait; transform: none; }
.btn-dark-slate { background: var(--text-main); color: #fff; border: none; border-radius: 12px; padding: 0.6rem 1.1rem; font-weight: 700; font-size: 0.84rem; display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem; transition: all var(--transition); cursor: pointer; }
.btn-dark-slate:hover { background: #1e293b; color: #fff; transform: translateY(-1px); }
.btn-soft { background: #f1f5f9; color: var(--text-secondary); border: 1px solid var(--border-color); border-radius: 12px; padding: 0.72rem 1.15rem; font-weight: 600; font-size: 0.88rem; transition: all var(--transition); cursor: pointer; }
.btn-soft:hover { background: #e2e8f0; color: var(--text-main); }

/* Settings Panel & Controls */
.settings-panel { background: #f8fafc; border: 1px solid var(--border-color); border-radius: 18px; padding: 1.4rem; height: 100%; }
.panel-title { font-size: 0.95rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1.15rem; }
.preset-chips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.42rem; margin-bottom: 1rem; }
.preset-chip { border: 1px solid var(--border-color); background: #fff; border-radius: 10px; padding: 0.52rem 0.35rem; font-size: 0.75rem; font-weight: 700; color: var(--text-secondary); text-align: center; cursor: pointer; transition: all var(--transition); line-height: 1.25; }
.preset-chip small { display: block; font-size: 0.67rem; font-weight: 600; color: var(--text-muted); margin-top: 2px; }
.preset-chip:hover { border-color: var(--brand-primary); color: var(--brand-primary); }
.preset-chip.active { background: var(--brand-soft); border-color: var(--brand-primary); color: var(--brand-primary); }
.preset-chip.active small { color: var(--brand-primary-hover); }

.quality-badge { background: var(--brand-primary); color: #fff; font-weight: 700; font-size: 0.82rem; padding: 0.2rem 0.65rem; border-radius: var(--radius-pill); }
.form-range { accent-color: var(--brand-primary); height: 6px; }
.form-control, .form-select { border-radius: 11px; border: 1.5px solid var(--border-color); padding: 0.55rem 0.85rem; font-size: 0.9rem; font-weight: 500; background-color: #fff; }
.form-control:focus, .form-select:focus { border-color: var(--brand-primary); box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.14); }
.form-check-input:checked { background-color: var(--brand-primary); border-color: var(--brand-primary); }

/* Queue & Reorder Controls */
.queue-card { border: 1px solid var(--border-color); border-radius: 18px; background: #fff; overflow: hidden; }
.queue-header { padding: 1rem 1.25rem; background: #f8fafc; border-bottom: 1px solid var(--border-color); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 0.65rem; }
#file-table th { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); font-weight: 700; background: #fcfcfd; border-bottom: 1px solid var(--border-color); padding: 0.75rem 1rem; }
#file-table td { vertical-align: middle; padding: 0.75rem 1rem; border-color: var(--border-color); font-size: 0.88rem; }
.thumb-img { width: 46px; height: 46px; border-radius: 10px; object-fit: cover; border: 1px solid var(--border-color); background: repeating-conic-gradient(#e2e8f0 0% 25%, #ffffff 0% 50%) 50% / 10px 10px; flex-shrink: 0; }
.pdf-icon-badge { width: 46px; height: 46px; border-radius: 10px; background: #fef2f2; border: 1px solid #fecaca; color: #dc2626; font-weight: 800; font-size: 0.74rem; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; letter-spacing: 0.03em; }
.dims-pill { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.76rem; font-weight: 700; padding: 0.22rem 0.6rem; border-radius: var(--radius-pill); background: var(--brand-soft); color: var(--brand-primary); border: 1px solid var(--brand-border); white-space: nowrap; }
.dims-pill-muted { background: #f1f5f9; color: var(--text-secondary); border-color: var(--border-color); }
.order-btn-group { display: inline-flex; align-items: center; gap: 0.25rem; }
.icon-action-btn { border: 1px solid var(--border-color); background: #fff; color: var(--text-muted); width: 30px; height: 30px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: all var(--transition); font-size: 0.8rem; font-weight: 700; }
.icon-action-btn:hover:not(:disabled) { border-color: var(--brand-primary); color: var(--brand-primary); background: var(--brand-soft); }
.icon-action-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.remove-row-btn:hover { background: #fef2f2 !important; color: #dc2626 !important; border-color: #fecaca !important; }

/* Progress & Results */
.progress-wrap { margin-top: 0.9rem; }
.progress { height: 8px; border-radius: var(--radius-pill); background: #e2e8f0; overflow: hidden; }
.progress-bar { background: var(--brand-gradient); transition: width 0.25s ease; }
.savings-banner { background: linear-gradient(135deg, #064e3b 0%, #0f172a 100%); color: #fff; border-radius: 16px; padding: 1.2rem 1.4rem; margin-bottom: 1rem; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.savings-stat { font-size: 1.3rem; font-weight: 800; color: #34d399; letter-spacing: -0.02em; }
.result-item { border: 1px solid var(--border-color); border-radius: 14px; padding: 0.9rem 1.15rem; margin-bottom: 0.65rem; background: #fff; display: flex; align-items: center; justify-content: space-between; gap: 0.9rem; flex-wrap: wrap; transition: all var(--transition); }
.result-item:hover { border-color: var(--brand-primary); box-shadow: var(--shadow-card); }
.result-meta { display: flex; align-items: center; gap: 0.85rem; min-width: 0; flex: 1; }
.result-meta > div { min-width: 0; flex: 1; overflow: hidden; }
.result-filename { font-size: 0.92rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; max-width: 100%; }
.badge-saved { background: var(--brand-soft); color: var(--brand-primary); border: 1px solid var(--brand-border); font-weight: 700; font-size: 0.76rem; padding: 0.28rem 0.68rem; border-radius: var(--radius-pill); white-space: nowrap; }
.status-alert { margin-top: 0.85rem; padding: 0.75rem 1rem; border-radius: 12px; font-size: 0.86rem; font-weight: 600; background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* Quick Tools Bar */
.quick-tools-bar { max-width: 1140px; margin: 1.25rem auto 3rem; padding: 0 1rem; }
.quick-tools-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.tool-pill {
  background: #fff; border: 1px solid var(--border-color); border-radius: var(--radius-pill);
  padding: 0.65rem 1rem; font-size: 0.84rem; font-weight: 600; color: var(--text-secondary);
  display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem;
  box-shadow: var(--shadow-xs); transition: all var(--transition); text-align: center; white-space: nowrap;
}
.tool-pill:hover { border-color: var(--brand-primary); color: var(--brand-primary); background: var(--brand-soft); transform: translateY(-2px); }
@media (max-width: 768px) {
  .quick-tools-grid { grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
  .tool-pill { padding: 0.6rem 0.75rem; font-size: 0.8rem; }
}

/* Editorial SEO Section (No Article Images) */
.editorial-section { max-width: 960px; margin: 0 auto; padding: 2rem 1rem; }
.editorial-eyebrow {
  display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.4rem 0.95rem;
  border-radius: var(--radius-pill); background: var(--brand-soft); border: 1px solid var(--brand-border);
  color: var(--brand-primary); font-size: 0.74rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 1rem;
}
.editorial-heading { font-size: clamp(1.75rem, 3.2vw, 2.4rem); font-weight: 800; letter-spacing: -0.035em; line-height: 1.2; color: var(--text-main); margin-bottom: 1.1rem; }
.editorial-lead { font-size: 1.08rem; line-height: 1.75; color: var(--text-secondary); margin-bottom: 1.5rem; }
.editorial-body p { font-size: 1rem; line-height: 1.8; color: var(--text-secondary); margin-bottom: 1.2rem; }
.editorial-body h3 { font-size: 1.28rem; font-weight: 800; letter-spacing: -0.02em; margin-top: 1.9rem; margin-bottom: 0.85rem; color: var(--text-main); }
.editorial-list { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: 0.75rem; }
.editorial-list li {
  display: flex; align-items: flex-start; gap: 0.7rem; font-size: 0.98rem; line-height: 1.65;
  color: var(--text-secondary); padding: 0.85rem 1rem; background: #ffffff;
  border: 1px solid var(--border-color); border-radius: 12px;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.editorial-list li:hover { border-color: var(--brand-border); box-shadow: var(--shadow-xs); }
.editorial-list .check-orb { width: 22px; height: 22px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-primary); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 0.1rem; }
.editorial-list strong { color: var(--text-main); font-weight: 700; }

/* FAQ & Footer */
.faq-card { background: #fff; border: 1px solid var(--border-color); border-radius: 16px; margin-bottom: 0.85rem; overflow: hidden; }
.faq-header .btn-link { color: var(--text-main); font-weight: 700; font-size: 0.98rem; text-decoration: none; padding: 1.15rem 1.35rem !important; display: flex; align-items: center; justify-content: space-between; width: 100%; text-align: left; }
.faq-header .btn-link:hover { color: var(--brand-primary); }
.faq-body { padding: 0 1.35rem 1.25rem; color: var(--text-secondary); font-size: 0.94rem; }

.dark-footer { position: relative; margin-top: 4rem; background: #0b1220; color: #94a3b8; padding: 3rem 1rem 1.5rem; text-align: center; overflow: hidden; }
.dark-footer::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--brand-gradient); }
.dark-footer::after { content: ""; position: absolute; top: -120px; left: 50%; transform: translateX(-50%); width: 520px; height: 240px; background: radial-gradient(ellipse, rgba(5, 150, 105, 0.28) 0%, transparent 70%); pointer-events: none; }
.df-inner { position: relative; z-index: 1; max-width: 640px; margin: 0 auto; }
.df-logo { display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem; font-weight: 800; font-size: 1.4rem; letter-spacing: -0.03em; color: #fff; text-decoration: none; }
.df-logo:hover { color: #fff; }
.df-tagline { font-size: 0.92rem; line-height: 1.7; margin: 0.9rem auto 1.25rem; color: #94a3b8; }
.df-badge { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.78rem; font-weight: 600; color: #34d399; background: rgba(52, 211, 153, 0.1); border: 1px solid rgba(52, 211, 153, 0.25); padding: 0.4rem 0.9rem; border-radius: var(--radius-pill); }
.df-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.2); }
.df-links { display: flex; justify-content: center; gap: 0.6rem; flex-wrap: wrap; margin: 1.75rem 0 0; }
.df-links a { font-size: 0.84rem; font-weight: 600; color: #e2e8f0; padding: 0.45rem 1rem; border: 1px solid rgba(148, 163, 184, 0.25); border-radius: var(--radius-pill); text-decoration: none; transition: all var(--transition); }
.df-links a:hover { color: #0b1220; background: #34d399; border-color: #34d399; }
.df-copy { position: relative; z-index: 1; margin-top: 2rem; font-size: 0.8rem; color: #64748b; }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (max-width: 768px) {
  .settings-panel { padding: 1.15rem; margin-bottom: 1.25rem; }
  .result-item { flex-direction: column; align-items: flex-start; }
  .result-item > div:last-child { width: 100%; justify-content: space-between; margin-top: 0.45rem; }
  .result-item .btn-dark-slate { flex-grow: 1; text-align: center; }
}
@media (max-width: 576px) {
  .studio-shell { padding: 1.15rem; }
  #file-table thead { display: none; }
  #file-table, #file-table tbody, #file-table tr, #file-table td { display: block; width: 100%; }
  #file-table tr { border-bottom: 1px solid var(--border-color); padding: 0.75rem 1rem; }
  #file-table td { display: flex; justify-content: space-between; align-items: center; border: none; padding: 0.3rem 0; }
  #file-table td::before { content: attr(data-label); font-weight: 700; font-size: 0.72rem; text-transform: uppercase; color: var(--text-muted); }
}
/* ========== UNIFIED MODERN PILL NAVBAR (ALL PAGES) ========== */
.navbar-wrapper {
  position: sticky;
  top: 12px;
  z-index: 1030;
  padding: 0 1rem;
  margin-bottom: 1.15rem;
}
.wc-navbar {
  max-width: 1180px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px) saturate(180%);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 999px;
  padding: 0.5rem 0.75rem 0.5rem 1rem;
  box-shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.12), 0 2px 6px rgba(15, 23, 42, 0.04);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: relative;
}
.wc-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none !important;
  color: #0f172a !important;
  font-weight: 800;
  font-size: 1.12rem;
  letter-spacing: -0.03em;
  white-space: nowrap;
  flex-shrink: 0;
}
.wc-brand:hover {
  color: #0f172a !important;
}
.wc-brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #059669 0%, #0d9488 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.32);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
.wc-brand:hover .wc-brand-icon {
  transform: scale(1.06) rotate(-4deg);
}
.wc-nav-toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}
.wc-nav-hamburger {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  margin: 0;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.wc-nav-hamburger:hover {
  background: #ecfdf5;
  border-color: #a7f3d0;
}
.wc-nav-hamburger span,
.wc-nav-hamburger span::before,
.wc-nav-hamburger span::after {
  display: block;
  width: 18px;
  height: 2px;
  background: #0f172a;
  border-radius: 2px;
  content: "";
  position: relative;
  transition: transform 0.22s ease, opacity 0.22s ease, background 0.22s ease;
}
.wc-nav-hamburger span::before {
  position: absolute;
  top: -6px;
  left: 0;
}
.wc-nav-hamburger span::after {
  position: absolute;
  top: 6px;
  left: 0;
}
.wc-nav-toggle:checked + .wc-nav-hamburger span {
  background: transparent;
}
.wc-nav-toggle:checked + .wc-nav-hamburger span::before {
  top: 0;
  transform: rotate(45deg);
}
.wc-nav-toggle:checked + .wc-nav-hamburger span::after {
  top: 0;
  transform: rotate(-45deg);
}
.wc-nav-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 1;
  gap: 0.75rem;
  min-width: 0;
}
.wc-nav-links {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  list-style: none;
  margin: 0 auto;
  padding: 4px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
}
.wc-nav-links li {
  margin: 0;
  padding: 0;
  list-style: none;
}
.wc-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.42rem 0.95rem;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 600;
  color: #475569 !important;
  text-decoration: none !important;
  white-space: nowrap;
  transition: all 0.2s ease;
}
.wc-nav-link:hover {
  color: #059669 !important;
  background: rgba(255, 255, 255, 0.75);
}
.wc-nav-link.is-active {
  background: #ffffff;
  color: #059669 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}
.wc-nav-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}
.wc-lang-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 38px;
  padding: 0 0.65rem 0 0.75rem;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  color: #0f172a;
  transition: all 0.2s ease;
}
.wc-lang-btn:hover,
.wc-lang-btn:focus-within {
  background: #ecfdf5;
  border-color: #059669;
  color: #065f46;
}
.wc-lang-globe {
  color: #059669;
  flex-shrink: 0;
  pointer-events: none;
}
.wc-lang-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 0.83rem;
  font-weight: 600;
  color: inherit;
  padding: 0 1.25rem 0 0.4rem;
  height: 100%;
  cursor: pointer;
  max-width: 145px;
  text-overflow: ellipsis;
}
.wc-lang-select:focus {
  outline: none;
  box-shadow: none;
}
.wc-lang-chevron {
  position: absolute;
  right: 0.65rem;
  color: #64748b;
  pointer-events: none;
}
.wc-all-tools-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  height: 38px;
  padding: 0 1.05rem;
  border-radius: 999px;
  background: #0f172a;
  color: #ffffff !important;
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none !important;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.14);
  transition: all 0.2s ease;
}
.wc-all-tools-btn:hover,
.wc-all-tools-btn.is-active {
  background: linear-gradient(135deg, #059669 0%, #0d9488 100%);
  color: #ffffff !important;
  box-shadow: 0 6px 16px rgba(5, 150, 105, 0.28);
  transform: translateY(-1px);
}
@media (max-width: 991px) {
  .wc-navbar {
    border-radius: 20px;
    flex-wrap: wrap;
    padding: 0.6rem 0.9rem;
    gap: 0.5rem;
  }
  .wc-nav-hamburger {
    display: inline-flex;
  }
  .wc-nav-body {
    display: none;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    flex: 0 0 100%;
    gap: 0.75rem;
    padding-top: 0.8rem;
    margin-top: 0.45rem;
    border-top: 1px solid #e2e8f0;
  }
  .wc-nav-toggle:checked ~ .wc-nav-body {
    display: flex;
  }
  .wc-nav-links {
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    border-radius: 14px;
    padding: 5px;
    gap: 4px;
  }
  .wc-nav-link {
    justify-content: flex-start;
    padding: 0.6rem 0.9rem;
    border-radius: 10px;
    font-size: 0.92rem;
  }
  .wc-nav-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    width: 100%;
  }
  .wc-lang-btn {
    width: 100%;
    height: 42px;
    justify-content: flex-start;
  }
  .wc-lang-select {
    width: 100%;
    max-width: none;
  }
  .wc-all-tools-btn {
    width: 100%;
    height: 42px;
  }
}
@media (max-width: 480px) {
  .wc-nav-actions {
    grid-template-columns: 1fr;
  }
}
/* ========== HOW TO SECTION (ALL PDF TOOL PAGES) ========== */
.howto-section {
  max-width: 1140px;
  margin: 0 auto 2.5rem;
  padding: 1.5rem 1rem 1rem;
}
.howto-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 2rem;
}
.howto-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.36rem 0.92rem;
  border-radius: var(--radius-pill);
  background: var(--brand-soft);
  border: 1px solid var(--brand-border);
  color: var(--brand-primary);
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.85rem;
}
.howto-heading {
  font-size: clamp(1.65rem, 3.1vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.2;
  color: var(--text-main);
  margin-bottom: 0.65rem;
}
.howto-sub {
  font-size: 0.98rem;
  color: var(--text-secondary);
  margin-bottom: 0;
  line-height: 1.65;
}
.howto-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.howto-card {
  background: var(--surface-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.55rem 1.45rem;
  box-shadow: var(--shadow-card);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.howto-card:hover {
  transform: translateY(-3px);
  border-color: var(--brand-border);
  box-shadow: var(--shadow-float);
}
.howto-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.15rem;
}
.howto-step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  padding: 0 0.8rem;
  border-radius: var(--radius-pill);
  background: var(--brand-gradient);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow: 0 6px 14px -6px rgba(5, 150, 105, 0.55);
}
.howto-step-icon {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  background: var(--brand-soft);
  border: 1px solid var(--brand-border);
  color: var(--brand-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.howto-step-title {
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 0.55rem;
  line-height: 1.35;
}
.howto-step-desc {
  font-size: 0.93rem;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 0;
}
@media (max-width: 900px) {
  .howto-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .howto-card {
    padding: 1.35rem 1.25rem;
  }
}

/* === TEXT TO PDF & PDF TO TEXT ENHANCEMENTS === */
.txt-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 36px;
  padding: 0 8px;
  border-radius: 10px;
  background: rgba(5, 150, 105, 0.12);
  color: var(--brand-primary, #059669);
  font-weight: 800;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  border: 1px solid rgba(5, 150, 105, 0.22);
  flex-shrink: 0;
}
.text-editor-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle, #e2e8f0);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 4px 18px -10px rgba(15, 23, 42, 0.08);
}
.text-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: #f8fafc;
  border-bottom: 1px solid var(--border-subtle, #e2e8f0);
}
.text-editor-textarea {
  width: 100%;
  min-height: 290px;
  padding: 1rem 1.15rem;
  border: 0;
  outline: none;
  resize: vertical;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  font-size: 0.95rem;
  line-height: 1.65;
  color: #0f172a;
  background: #ffffff;
}
.text-editor-textarea:focus {
  background: #fcfefd;
}
.text-stats-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.6rem 1rem;
  background: #f8fafc;
  border-top: 1px solid var(--border-subtle, #e2e8f0);
  font-size: 0.8rem;
  color: #64748b;
  font-weight: 600;
}
.extracted-text-card {
  background: #ffffff;
  border: 1px solid var(--border-subtle, #e2e8f0);
  border-radius: 16px;
  padding: 1rem;
  margin-bottom: 0.85rem;
  box-shadow: 0 4px 14px -10px rgba(15, 23, 42, 0.08);
}
.extracted-text-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}
.extracted-text-pre {
  width: 100%;
  min-height: 170px;
  max-height: 320px;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #0f172a;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.84rem;
  line-height: 1.55;
  resize: vertical;
  white-space: pre-wrap;
}
.btn-copy-text {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(5, 150, 105, 0.28);
  background: rgba(5, 150, 105, 0.08);
  color: #047857;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.16s ease;
}
.btn-copy-text:hover {
  background: #059669;
  color: #ffffff;
  border-color: #059669;
}

/* === RICH TEXT TOOLBAR (TEXT TO PDF) === */
.rte-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px;
  padding: 0.55rem 0.75rem;
  background: #f1f5f9;
  border-bottom: 1px solid var(--border-subtle, #e2e8f0);
}
.rte-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #334155;
  font-size: 0.86rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease, border-color 0.14s ease;
  position: relative;
  flex-shrink: 0;
}
.rte-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}
.rte-btn.is-active {
  background: rgba(5, 150, 105, 0.14);
  color: #047857;
  border-color: rgba(5, 150, 105, 0.32);
}
.rte-btn-danger {
  background: #ef4444;
  color: #ffffff;
  border-radius: 50%;
  width: 26px;
  height: 26px;
  margin-left: 4px;
}
.rte-btn-danger:hover {
  background: #dc2626;
  color: #ffffff;
}
.rte-color-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.rte-color-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
  border: 0;
  padding: 0;
}
.rte-sep {
  width: 1px;
  height: 20px;
  background: #cbd5e1;
  margin: 0 3px;
  flex-shrink: 0;
}
.rich-editor-area {
  width: 100%;
  min-height: 300px;
  max-height: 520px;
  overflow-y: auto;
  padding: 1rem 1.2rem;
  border: 0;
  outline: none;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  font-size: 0.96rem;
  line-height: 1.68;
  color: #0f172a;
  background: #ffffff;
  word-wrap: break-word;
}
.rich-editor-area:focus {
  background: #fcfefd;
}
.rich-editor-area:empty::before {
  content: attr(data-placeholder);
  color: #94a3b8;
  pointer-events: none;
  display: block;
}
.rich-editor-area blockquote {
  border-left: 3px solid #059669;
  background: #f0fdf4;
  margin: 0.6rem 0;
  padding: 0.45rem 0.9rem;
  color: #1e293b;
  border-radius: 0 8px 8px 0;
}
.rich-editor-area pre, .rich-editor-area code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: #f1f5f9;
  border-radius: 6px;
  font-size: 0.88em;
}
.rich-editor-area pre {
  padding: 0.65rem 0.85rem;
  margin: 0.5rem 0;
  overflow-x: auto;
  border: 1px solid #e2e8f0;
}
.rich-editor-area code {
  padding: 0.12rem 0.35rem;
}
.rich-editor-area ul, .rich-editor-area ol {
  padding-left: 1.5rem;
  margin: 0.4rem 0;
}
.rich-editor-area a {
  color: #059669;
  text-decoration: underline;
}
@media (max-width: 576px) {
  .rte-toolbar {
    padding: 0.45rem 0.5rem;
    gap: 2px;
  }
  .rte-btn {
    width: 30px;
    height: 30px;
  }
}

/* === HIGHLIGHTED UPLOAD TXT BUTTON === */
.btn-upload-txt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.55rem 0.95rem;
  box-shadow: 0 8px 18px -8px rgba(244, 63, 94, 0.65);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
  cursor: pointer;
}
.btn-upload-txt:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px -8px rgba(225, 29, 72, 0.72);
  filter: brightness(1.06);
  color: #ffffff;
}
.btn-upload-txt:active {
  transform: translateY(0);
}
