/* ============================================================
   HobbyPDF — styles.css
   Clean, modern, minimal. Inter + a single violet accent.
   ============================================================ */

:root {
  --violet: #6366F1;
  --violet-dark: #4F46E5;
  --violet-soft: #EEF0FF;
  --orange: #FF8A3D;
  --bg: #FFFFFF;
  --bg-muted: #F9FAFB;
  --ink: #111827;
  --gray: #6B7280;
  --gray-light: #9CA3AF;
  --border: #E5E7EB;
  --green: #16A34A;
  --green-soft: #ECFDF3;
  --red: #DC2626;
  --red-soft: #FEF2F2;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(17, 24, 39, 0.05);
  --shadow-md: 0 8px 24px rgba(17, 24, 39, 0.08);
  --shadow-lg: 0 20px 50px rgba(79, 70, 229, 0.12);
  --ease: 250ms cubic-bezier(0.4, 0, 0.2, 1);

  --maxw: 720px;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.wordmark-icon { display: inline-flex; }
.site-nav {
  display: flex;
  gap: 28px;
  font-size: 15px;
  font-weight: 500;
  color: var(--gray);
}
.site-nav a { transition: color var(--ease); }
.site-nav a:hover { color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  padding: 64px 0 56px;
  text-align: center;
}
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--violet);
  background: var(--violet-soft);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 20px;
}
.hero h1 {
  font-size: 54px;
  font-weight: 800;
  letter-spacing: -0.035em;
}
.subhead {
  font-size: 19px;
  color: var(--gray);
  margin: 18px auto 0;
  max-width: 480px;
}

/* ---------- The tool ---------- */
.tool {
  margin-top: 40px;
  text-align: left;
}

/* Drop zone */
.dropzone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 48px 24px;
  background: var(--bg-muted);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  text-align: center;
  transition: border-color var(--ease), background var(--ease), transform var(--ease), box-shadow var(--ease);
}
.dropzone:hover {
  border-color: var(--violet);
  background: #fff;
}
.dropzone:focus-visible {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 4px var(--violet-soft);
}
.dropzone.is-dragover {
  border-color: var(--violet);
  background: var(--violet-soft);
  transform: scale(1.01);
  box-shadow: var(--shadow-lg);
}
.dropzone-icon {
  color: var(--violet);
  margin-bottom: 6px;
  transition: transform var(--ease);
}
.dropzone.is-dragover .dropzone-icon { transform: translateY(-4px); }
.dropzone-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
}
.dropzone-hint {
  font-size: 14.5px;
  color: var(--gray);
}
.link-text {
  color: var(--violet);
  font-weight: 600;
}

/* Alert / messages */
.alert {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: fade-in 250ms ease;
}
.alert.is-error {
  background: var(--red-soft);
  color: var(--red);
  border: 1px solid #FECACA;
}
.alert.is-warn {
  background: #FFFBEB;
  color: #B45309;
  border: 1px solid #FDE68A;
}

/* File list */
.file-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.file-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--ease), border-color var(--ease), transform var(--ease), opacity var(--ease);
  animation: item-in 280ms cubic-bezier(0.4, 0, 0.2, 1);
}
.file-item:hover {
  border-color: #D8DAE0;
  box-shadow: var(--shadow-md);
}
.file-item.is-removing {
  opacity: 0;
  transform: translateX(12px);
}
.file-item.is-dragging {
  opacity: 0.5;
  border-color: var(--violet);
  border-style: dashed;
}
.file-item.drop-target { box-shadow: 0 0 0 2px var(--violet); }

.file-grip {
  display: flex;
  flex-direction: column;
  gap: 3px;
  color: var(--gray-light);
  cursor: grab;
  padding: 2px;
  touch-action: none;
}
.file-grip:active { cursor: grabbing; }
.file-grip span {
  display: block;
  width: 14px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

.file-thumb {
  flex: 0 0 auto;
  width: 38px;
  height: 48px;
  border-radius: 6px;
  background: var(--violet-soft);
  color: var(--violet);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  position: relative;
  overflow: hidden;
}
.file-thumb::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  border-width: 0 9px 9px 0;
  border-style: solid;
  border-color: #fff var(--bg-muted);
}

.file-meta {
  flex: 1 1 auto;
  min-width: 0;
}
.file-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.file-sub {
  font-size: 13px;
  color: var(--gray);
  margin-top: 2px;
}
.file-sub.is-error { color: var(--red); font-weight: 500; }

.file-reorder {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 22px;
  border: none;
  background: transparent;
  color: var(--gray-light);
  border-radius: 6px;
  cursor: pointer;
  transition: background var(--ease), color var(--ease);
}
.icon-btn:hover:not(:disabled) { background: var(--bg-muted); color: var(--ink); }
.icon-btn:disabled { opacity: 0.3; cursor: default; }

.file-remove {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: none;
  background: transparent;
  color: var(--gray-light);
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background var(--ease), color var(--ease);
}
.file-remove:hover { background: var(--red-soft); color: var(--red); }

/* Action bar */
.action-bar {
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.action-summary {
  font-size: 14.5px;
  color: var(--gray);
  font-weight: 500;
}

/* Buttons */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-sm);
  padding: 14px 26px;
  min-height: 50px;
  cursor: pointer;
  transition: transform var(--ease), box-shadow var(--ease), background var(--ease), opacity var(--ease);
  white-space: nowrap;
}
.btn-primary {
  background: var(--violet);
  color: #fff;
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.32);
}
.btn-primary:hover:not(:disabled) {
  background: var(--violet-dark);
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 10px 22px rgba(99, 102, 241, 0.4);
}
.btn-primary:active:not(:disabled) { transform: translateY(0) scale(0.99); }
.btn-primary:disabled {
  background: #C7C9D9;
  box-shadow: none;
  cursor: not-allowed;
}
.btn-ghost {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.btn-ghost:hover { border-color: var(--gray-light); background: var(--bg-muted); }

.action-bar .btn-primary { flex: 0 0 auto; min-width: 180px; }

/* Loading spinner on merge button */
.spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2.5px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}
.btn.is-loading .btn-label { opacity: 0.85; }
.btn.is-loading .spinner { display: inline-block; }

/* Success state */
.success {
  margin-top: 8px;
  text-align: center;
  padding: 40px 24px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  animation: fade-in 350ms ease;
}
.success-check {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pop 420ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.success-title { font-size: 24px; font-weight: 700; }
.success-text { color: var(--gray); margin-top: 8px; font-size: 15.5px; }
.success-actions {
  margin-top: 26px;
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.trust-line {
  margin-top: 22px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  color: var(--gray);
}
.trust-line svg { color: var(--green); }

/* ---------- Features ---------- */
.features {
  padding: 56px 0;
  background: var(--bg-muted);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.feature-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 22px;
  transition: transform var(--ease), box-shadow var(--ease);
}
.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.feature-emoji { font-size: 28px; line-height: 1; }
.feature-card h3 { font-size: 17px; font-weight: 700; margin-top: 14px; }
.feature-card p { font-size: 14.5px; color: var(--gray); margin-top: 8px; }

/* ---------- FAQ ---------- */
.faq { padding: 64px 0; }
.section-title {
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-align: center;
  margin-bottom: 32px;
}
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  overflow: hidden;
  transition: box-shadow var(--ease), border-color var(--ease);
}
.faq-item[open] { border-color: #D8DAE0; box-shadow: var(--shadow-sm); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 20px;
  font-size: 16.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '';
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--gray-light);
  border-bottom: 2px solid var(--gray-light);
  transform: rotate(45deg);
  transition: transform var(--ease);
}
.faq-item[open] summary::after { transform: rotate(-135deg); }
.faq-item p {
  padding: 0 20px 20px;
  color: var(--gray);
  font-size: 15.5px;
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 40px 0;
  background: var(--bg-muted);
  border-top: 1px solid var(--border);
}
.footer-inner { text-align: center; }
.footer-brand { font-size: 15px; font-weight: 600; }
.footer-brand a { color: var(--violet); }
.footer-brand a:hover { text-decoration: underline; }
.footer-privacy { font-size: 14px; color: var(--gray); margin-top: 8px; }
.footer-contact { font-size: 14px; color: var(--gray); margin-top: 6px; }
.footer-contact a { color: var(--violet); font-weight: 600; }
.footer-contact a:hover { text-decoration: underline; }

/* ---------- Animations ---------- */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fade-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@keyframes item-in { from { opacity: 0; transform: translateY(-8px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes pop { 0% { transform: scale(0.4); opacity: 0; } 60% { transform: scale(1.08); } 100% { transform: scale(1); opacity: 1; } }

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  .hero h1 { font-size: 40px; }
  .subhead { font-size: 17px; }
  .feature-grid { grid-template-columns: 1fr; }
  .section-title { font-size: 27px; }
}

@media (max-width: 460px) {
  body { font-size: 16px; }
  .hero { padding: 44px 0 40px; }
  .hero h1 { font-size: 33px; }
  .dropzone { padding: 36px 16px; }
  .site-nav { gap: 18px; font-size: 14px; }
  .action-bar { flex-direction: column; align-items: stretch; }
  .action-bar .btn-primary { width: 100%; }
  .success-actions .btn { flex: 1 1 auto; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============================================================
   Shared tools additions — nav, splitter, compressor, tools index.
   Appended (never rewrites the rules above). Reuses the same
   variables and component patterns as the merger.
   ============================================================ */

/* ---------- Product nav (active states) ---------- */
.site-nav { position: relative; }
.site-nav a {
  position: relative;
  padding: 4px 0;
  white-space: nowrap;
}
.site-nav a.is-active {
  color: var(--ink);
  font-weight: 600;
}
.site-nav a.is-active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 2px;
  border-radius: 2px;
  background: var(--violet);
}

/* On small screens let the nav scroll horizontally rather than wrap. */
@media (max-width: 540px) {
  .site-nav {
    gap: 18px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    max-width: 62vw;
    justify-content: flex-end;
  }
  .site-nav::-webkit-scrollbar { display: none; }
}

/* ---------- Single-file info card (split + compress) ---------- */
.fileinfo {
  margin-top: 16px;
}

/* ---------- Generic option panel (split modes + compress options) ---------- */
.panel {
  margin-top: 22px;
  padding: 22px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  animation: fade-in 250ms ease;
}
.panel-title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 16px;
}

/* ---------- Split: mode selector ---------- */
.mode-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.mode-option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color var(--ease), background var(--ease), box-shadow var(--ease);
}
.mode-option:hover { border-color: #D8DAE0; }
.mode-option:has(input:checked),
.mode-option.is-selected {
  border-color: var(--violet);
  background: var(--violet-soft);
  box-shadow: 0 0 0 1px var(--violet);
}
.mode-option input[type="radio"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--violet);
  cursor: pointer;
}
.mode-body { flex: 1 1 auto; min-width: 0; }
.mode-name { font-size: 15.5px; font-weight: 600; color: var(--ink); display: block; }
.mode-desc { font-size: 13.5px; color: var(--gray); margin-top: 2px; display: block; }
.mode-control {
  display: none;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  font-size: 14.5px;
  color: var(--ink);
  font-weight: 500;
}
.mode-option:has(input:checked) .mode-control,
.mode-option.is-selected .mode-control { display: flex; }

.num-input,
.text-input {
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.num-input { width: 78px; text-align: center; }
.text-input { width: 100%; max-width: 320px; }
.num-input:focus,
.text-input:focus {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 3px var(--violet-soft);
}
.field-hint { font-size: 13px; color: var(--gray); margin-top: 6px; }

/* ---------- Split: live preview ---------- */
.preview {
  margin-top: 20px;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  animation: fade-in 250ms ease;
}
.preview.is-invalid { border-color: #FECACA; background: var(--red-soft); }
.preview-head {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 10px;
}
.preview.is-invalid .preview-head { color: var(--red); margin-bottom: 0; }
.preview-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 260px;
  overflow-y: auto;
}
.preview-list li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: 14px;
  color: var(--gray);
}
.preview-list .pv-name {
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.preview-more { font-size: 13px; color: var(--gray-light); margin-top: 4px; }

/* ---------- Download choice (split) ---------- */
.choice-row {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.choice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
}
.choice input[type="radio"] {
  width: 17px;
  height: 17px;
  accent-color: var(--violet);
  cursor: pointer;
}

/* ---------- Compress: honesty notice (static warn banner) ---------- */
.notice {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  line-height: 1.5;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #FFFBEB;
  color: #92400E;
  border: 1px solid #FDE68A;
}
.notice svg { flex: 0 0 auto; margin-top: 2px; color: #D97706; }
.notice strong { color: #B45309; }

/* ---------- Compress: option checkboxes ---------- */
.check-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--ease);
}
.check:hover { background: #fff; }
.check input[type="checkbox"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--violet);
  cursor: pointer;
}
.check-body { flex: 1 1 auto; min-width: 0; }
.check-name { font-size: 15px; font-weight: 600; color: var(--ink); display: block; }
.check-desc { font-size: 13.5px; color: var(--gray); margin-top: 2px; display: block; }

/* ---------- Compress: before/after comparison ---------- */
.compare {
  margin-top: 8px;
  padding: 26px 24px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  animation: fade-in 350ms ease;
}
.compare.is-flat { /* "already optimized" state */ }
.compare-bars {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.compare-stat { text-align: center; }
.compare-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gray);
}
.compare-value {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}
.compare-value.is-after { color: var(--violet); }
.compare-arrow { color: var(--gray-light); display: inline-flex; }
.compare-headline {
  font-size: 20px;
  font-weight: 700;
  color: var(--green);
}
.compare.is-flat .compare-headline { color: var(--ink); }
.compare-sub {
  font-size: 14.5px;
  color: var(--gray);
  margin-top: 8px;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}
.compare-actions {
  margin-top: 24px;
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------- Tools index: card grid ---------- */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 8px;
}
.tool-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 22px;
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}
a.tool-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: #D8DAE0;
}
.tool-card-icon {
  font-size: 30px;
  line-height: 1;
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--violet-soft);
  border-radius: 12px;
  margin-bottom: 16px;
}
.tool-card h3 { font-size: 18px; font-weight: 700; }
.tool-card p { font-size: 14.5px; color: var(--gray); margin-top: 8px; flex: 1 1 auto; }
.tool-card-cta {
  margin-top: 18px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--violet);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
a.tool-card:hover .tool-card-cta { gap: 9px; }
.tool-card.is-soon {
  background: var(--bg-muted);
  cursor: default;
}
.tool-card.is-soon .tool-card-icon { background: #EFF0F3; filter: grayscale(1); opacity: 0.7; }
.tool-card.is-soon h3 { color: var(--gray); }
.tool-card.is-soon p { color: var(--gray-light); }
.tool-card-badge {
  margin-top: 18px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--gray-light);
  background: #EFF0F3;
  padding: 4px 10px;
  border-radius: 999px;
}

/* Footer "more tools" link */
.footer-tools { font-size: 14px; margin-top: 6px; }
.footer-tools a { color: var(--violet); font-weight: 600; }
.footer-tools a:hover { text-decoration: underline; }

@media (max-width: 760px) {
  .tools-grid { grid-template-columns: 1fr; }
}

/* ---------- Language switch ---------- */
.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 16px;
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  border-radius: 999px;
}
.lang-btn {
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--gray);
  background: transparent;
  border: none;
  border-radius: 999px;
  padding: 5px 11px;
  cursor: pointer;
  transition: background var(--ease), color var(--ease);
}
.lang-btn:hover { color: var(--ink); }
.lang-btn.is-active {
  background: #fff;
  color: var(--violet);
  box-shadow: var(--shadow-sm);
}

@media (max-width: 540px) {
  .header-actions { gap: 10px; }
  .lang-btn { padding: 5px 9px; font-size: 12px; }
  .site-nav { max-width: 44vw; }
}

/* ---------- Select input (image-to-pdf, pdf-to-image) ---------- */
.select-input {
  font-family: inherit;
  font-size: 14.5px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 30px 9px 12px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 9px center;
  transition: border-color var(--ease), box-shadow var(--ease);
}
.select-input:focus {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 3px var(--violet-soft);
}
.opt-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-top: 14px;
}
.opt-row:first-of-type { margin-top: 0; }
.opt-label { font-size: 14.5px; font-weight: 600; color: var(--ink); }

/* ---------- Rotate: angle preview chip ---------- */
.rotate-preview {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 4px;
  font-size: 14.5px;
  color: var(--gray);
}
.rotate-amount {
  font-weight: 700;
  color: var(--violet);
  font-variant-numeric: tabular-nums;
}

/* ---------- Progress line (pdf-to-image) ---------- */
.progress-line {
  margin-top: 14px;
  font-size: 14px;
  color: var(--gray);
  font-weight: 500;
  text-align: center;
}
