/* PDF2Scan marketing pages (guides, comparisons, blog hub).
   Same tokens, navigation, buttons, FAQ, CTA banner and footer as the landing page (index.html). */
:root {
  --bg: #fafaf9;
  --alt: #f3f2ef;
  --surface: #ffffff;
  --border: #e8e6e1;
  --separator: #e6e4df;
  --text: #1a1917;
  --muted: #6b6860;
  --accent: oklch(52% 0.18 248);
  --accent-hover: oklch(46% 0.18 248);
  --accent-lt: oklch(96% 0.04 248);
  --accent-dk: oklch(38% 0.18 248);
  --accent-ring: oklch(52% 0.18 248 / 0.32);
  --success: oklch(50% 0.15 155);
  --amber: oklch(68% 0.17 68);
  --sans: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1120px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-size-adjust: 100%; }
body { font: 400 17px/1.5 var(--sans); background: var(--bg); color: var(--text); overflow-x: hidden; caret-color: var(--accent); }
::selection { background: oklch(52% 0.18 248 / 0.18); }
:focus-visible { outline: 3px solid var(--accent-ring); outline-offset: 3px; border-radius: 8px; }
a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.container { width: min(var(--wrap), 100% - 40px); margin: 0 auto; }

/* Buttons (landing) */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 18px; border: 0; border-radius: 999px; font: 600 15px var(--sans); white-space: nowrap; cursor: pointer; transition: background-color 160ms var(--ease), color 160ms var(--ease), transform 120ms var(--ease); }
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-tinted { background: var(--accent-lt); color: var(--accent-dk); }
.btn-tinted:hover { background: oklch(93% 0.06 248); }
.btn-lg { min-height: 50px; padding: 0 26px; font-size: 17px; }
.btn-sm { min-height: 34px; padding: 0 14px; font-size: 14px; }
.link-more { display: inline-flex; align-items: center; gap: 4px; color: var(--accent); font-size: 17px; font-weight: 500; }
.link-more::after { content: ""; width: 7px; height: 7px; border-top: 1.6px solid currentColor; border-right: 1.6px solid currentColor; transform: rotate(45deg); margin-left: 2px; }
.link-more:hover { text-decoration: underline; text-underline-offset: 4px; }
[dir="rtl"] .link-more::after { transform: rotate(-135deg); }

/* Navigation (landing) */
nav.site-nav { position: sticky; top: 0; z-index: 50; background: rgba(250, 250, 249, 0.8); border-bottom: 1px solid rgba(26, 25, 23, 0.06); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); }
.nav-inner { display: flex; align-items: center; gap: 28px; height: 56px; }
.nav-logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; font-size: 17px; letter-spacing: -0.02em; }
.nav-logo img { width: 26px; height: 26px; object-fit: contain; }
.nav-links { display: flex; gap: 24px; margin-inline-start: auto; font-size: 14px; color: var(--muted); }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-cta { display: flex; align-items: center; gap: 10px; }
.locale-select select { -webkit-appearance: none; appearance: none; height: 32px; padding: 0 26px 0 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5 6 7.5 9 4.5' fill='none' stroke='%236b6860' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 8px center; color: var(--text); font: 500 13px var(--sans); cursor: pointer; }

/* Article header */
.page-head { padding: 72px 0 40px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 14px; color: var(--muted); }
.crumbs a:hover { color: var(--text); }
.crumbs span[aria-hidden] { opacity: 0.5; }
.eyebrow { display: inline-block; margin-top: 28px; padding: 4px 10px; border-radius: 999px; background: var(--accent-lt); color: var(--accent-dk); font-size: 13px; font-weight: 600; }
.page-title { max-width: 20ch; margin-top: 16px; font-size: clamp(38px, 5.6vw, 64px); line-height: 1.04; font-weight: 700; letter-spacing: -0.035em; text-wrap: balance; }
.page-lead { max-width: 680px; margin-top: 20px; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--muted); text-wrap: pretty; }
.page-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 22px; font-size: 14px; color: var(--muted); }
.page-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 30px; }

/* Article layout */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 64px; align-items: start; padding-bottom: 96px; }
.article-aside { position: sticky; top: 80px; display: grid; gap: 16px; }
.toc { padding: 20px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--border); font-size: 14px; }
.toc-title { font-weight: 600; margin-bottom: 10px; }
.toc ol { list-style: none; display: grid; gap: 8px; }
.toc a { color: var(--muted); line-height: 1.35; }
.toc a:hover { color: var(--accent); }
.try-card { padding: 22px; border-radius: 16px; background: var(--text); color: #f5f4f1; }
.try-card strong { display: block; font-size: 18px; line-height: 1.25; letter-spacing: -0.01em; }
.try-card p { margin: 8px 0 16px; color: #b9b6ae; font-size: 14px; line-height: 1.5; }
.try-card .btn { width: 100%; }

.prose { min-width: 0; max-width: 720px; font-size: 18px; line-height: 1.7; }
.gallery { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
.gallery figure { margin: 0; }
.gallery img { border-radius: 10px; box-shadow: 0 0 0 1px var(--border); }
.gallery figcaption { text-align: center; }
.prose > * + * { margin-top: 20px; }
.prose h2 { margin-top: 64px; font-size: clamp(28px, 3vw, 36px); line-height: 1.12; font-weight: 700; letter-spacing: -0.025em; scroll-margin-top: 80px; text-wrap: balance; }
.prose h3 { margin-top: 36px; font-size: 21px; line-height: 1.3; font-weight: 650; letter-spacing: -0.01em; }
.prose h2 + *, .prose h3 + * { margin-top: 14px; }
.prose p, .prose li { color: #3a3833; }
.prose a { color: var(--accent-dk); text-decoration: underline; text-decoration-color: oklch(52% 0.18 248 / 0.35); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
.prose a.btn { color: #fff; text-decoration: none; }
.prose ul, .prose ol { padding-inline-start: 24px; display: grid; gap: 8px; }
.prose strong { color: var(--text); font-weight: 650; }
.prose code { padding: 2px 6px; border-radius: 6px; background: var(--alt); font: 500 0.88em var(--mono); }
.prose pre { overflow-x: auto; padding: 18px 20px; border-radius: 14px; background: #1a1917; color: #ecebe6; font: 14px/1.6 var(--mono); }
.prose pre code { padding: 0; background: none; color: inherit; font-size: inherit; }
.prose figure { margin-top: 28px; }
.prose figcaption { margin-top: 10px; font-size: 14px; color: var(--muted); }

.answer-box { padding: 22px 24px; border-radius: 16px; background: var(--surface); box-shadow: 0 0 0 1px var(--border); border-inline-start: 4px solid var(--accent); }
.answer-box .label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 700; letter-spacing: 0.02em; text-transform: uppercase; color: var(--accent-dk); }
.answer-box p { color: var(--text); }
.takeaways { padding: 22px 24px; border-radius: 16px; background: var(--alt); }
.takeaways .label { display: block; margin-bottom: 10px; font-weight: 650; }
.takeaways ul { display: grid; gap: 8px; }
.callout { padding: 18px 20px; border-radius: 14px; background: var(--accent-lt); color: var(--accent-dk); font-size: 16px; line-height: 1.6; }
.callout strong { color: inherit; }
.callout.warn { background: oklch(96% 0.05 80); color: oklch(42% 0.11 60); }

.steps-list { list-style: none; padding: 0 !important; counter-reset: step; display: grid; gap: 14px !important; }
.steps-list li { position: relative; padding: 18px 20px 18px 64px; border-radius: 14px; background: var(--surface); box-shadow: 0 0 0 1px var(--border); counter-increment: step; }
.steps-list li::before { content: counter(step); position: absolute; inset-inline-start: 18px; top: 16px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: #fff; font-size: 14px; font-weight: 700; }
[dir="rtl"] .steps-list li { padding: 18px 64px 18px 20px; }

.table-wrap { overflow-x: auto; margin-top: 24px; border-radius: 14px; box-shadow: 0 0 0 1px var(--border); background: var(--surface); }
.table-wrap table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15px; line-height: 1.45; }
.table-wrap th, .table-wrap td { padding: 13px 14px; border-bottom: 1px solid var(--separator); text-align: start; vertical-align: top; }
.table-wrap thead th { background: var(--alt); font-weight: 650; font-size: 14px; color: var(--text); }
.table-wrap tbody tr:last-child td { border-bottom: 0; }
.table-wrap td { color: #3a3833; }
.table-wrap td:first-child { color: var(--text); font-weight: 600; }
.table-wrap tr.highlight td { background: oklch(98% 0.02 248); }
.table-caption { margin-top: 10px; font-size: 14px; color: var(--muted); }

/* FAQ (landing look, native details) */
.faq { margin-top: 72px; }
.faq h2 { margin-bottom: 18px; }
.faq-list { border-top: 1px solid var(--separator); }
.faq-item { border-bottom: 1px solid var(--separator); }
.faq-item summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 0; list-style: none; cursor: pointer; font: 600 19px/1.35 var(--sans); letter-spacing: -0.01em; color: var(--text); }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-icon { width: 28px; height: 28px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--alt); transition: transform 240ms var(--ease), background-color 150ms var(--ease); }
.faq-icon svg { width: 10px; height: 10px; stroke: var(--text); stroke-width: 1.6; fill: none; stroke-linecap: round; transform: rotate(45deg); }
.faq-item[open] .faq-icon { transform: rotate(45deg); background: var(--accent-lt); }
.faq-item .faq-a { max-width: 68ch; padding: 0 0 24px; font-size: 17px; line-height: 1.65; color: var(--muted); }

/* Related guides and hub cards */
.related { padding: 96px 0; background: var(--alt); }
.related-title { font-size: clamp(28px, 3vw, 36px); font-weight: 700; letter-spacing: -0.025em; }
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 28px; }
.guide-card { display: flex; flex-direction: column; gap: 10px; padding: 24px; border-radius: 18px; background: var(--surface); box-shadow: 0 0 0 1px var(--border); transition: box-shadow 160ms var(--ease), transform 160ms var(--ease); }
.guide-card:hover { box-shadow: 0 0 0 1px var(--accent), 0 12px 32px -12px rgba(26, 25, 23, 0.18); transform: translateY(-2px); }
.guide-card .tag { align-self: flex-start; padding: 3px 9px; border-radius: 999px; background: var(--accent-lt); color: var(--accent-dk); font-size: 12px; font-weight: 600; }
.guide-card strong { font-size: 19px; line-height: 1.3; letter-spacing: -0.01em; }
.guide-card p { color: var(--muted); font-size: 15px; line-height: 1.55; }
.guide-card .link-more { margin-top: auto; font-size: 15px; }
.hub-section { padding: 0 0 72px; }
.hub-section h2 { font-size: clamp(24px, 2.6vw, 30px); font-weight: 700; letter-spacing: -0.02em; }

/* CTA banner (landing) */
.cta-banner { padding: 120px 0; text-align: center; background: var(--surface); border-top: 1px solid var(--separator); }
.cta-banner-title { font-size: clamp(36px, 5vw, 60px); line-height: 1.04; font-weight: 700; letter-spacing: -0.035em; text-wrap: balance; }
.cta-banner-sub { max-width: 560px; margin: 20px auto 0; font-size: 19px; line-height: 1.55; color: var(--muted); }
.cta-banner-actions { display: flex; align-items: center; justify-content: center; gap: 24px; margin-top: 36px; flex-wrap: wrap; }

/* Footer (landing) */
footer.site-footer { padding: 56px 0 40px; background: var(--alt); font-size: 14px; }
.footer-inner { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 40px; }
.footer-brand p { max-width: 300px; margin-top: 14px; color: var(--muted); line-height: 1.6; }
.footer-col-title { font-size: 13px; font-weight: 600; color: var(--text); }
.footer-links { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: var(--text); }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--separator); color: var(--muted); font-size: 13px; }

@media (max-width: 1000px) {
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .article-aside { position: static; order: -1; }
  .toc { display: none; }
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav-links { display: none; }
  .nav-cta { margin-inline-start: auto; }
  .page-head { padding: 44px 0 28px; }
  .prose { font-size: 17px; }
  .prose h2 { margin-top: 48px; }
  .card-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-title { font-size: clamp(32px, 9vw, 44px); }
  .nav-cta .btn { padding: 0 12px; }
  .related { padding: 72px 0; }
  .faq-item summary { font-size: 17px; padding: 20px 0; }
  .cta-banner { padding: 88px 0; }
  .footer-inner { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
