/* LexiFont.app — marketing site styles.
   Single file, no framework, deliberately light. Targets Core Web Vitals.
   Uses Atkinson Hyperlegible for body copy (accessibility-friendly). */

:root {
  --bg: #fdfcf9;
  --fg: #1c2231;
  --muted: #4b5563;
  --subtle: #667085;
  --border: #e6e7eb;
  --accent: #5b5bd6;
  --accent-2: #a855f7;
  --accent-soft: #eef0ff;
  --card: #ffffff;
  --success: #16a34a;
  --max: 1120px;
  --radius: 14px;
  --shadow: 0 12px 28px rgba(28, 34, 49, 0.08);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Atkinson Hyperlegible", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: "Lexend", "Atkinson Hyperlegible", sans-serif;
  line-height: 1.2;
  color: var(--fg);
  margin: 0 0 0.5rem;
}

h1 { font-size: clamp(2rem, 4vw + 1rem, 3.25rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.5rem, 2vw + 0.8rem, 2.25rem); font-weight: 700; letter-spacing: -0.005em; }
h3 { font-size: 1.15rem; font-weight: 600; }

p { margin: 0 0 0.75rem; color: var(--muted); }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; display: block; }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}

.narrow { max-width: 760px; }

.skip {
  position: absolute;
  left: -9999px;
  top: -9999px;
}
.skip:focus {
  position: fixed;
  left: 1rem; top: 1rem;
  background: var(--fg); color: white;
  padding: 0.5rem 0.75rem; border-radius: 6px; z-index: 100;
}

/* ===== Nav ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(253, 252, 249, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
}

.brand {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  font-weight: 700;
  color: var(--fg);
  text-decoration: none;
  font-size: 17px;
  font-family: "Lexend", sans-serif;
}

.nav nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 22px;
  align-items: center;
}

.nav nav a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.nav nav a:hover { color: var(--accent); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none !important;
  transition: transform 0.12s, background 0.15s, color 0.15s;
}

.btn-primary {
  background: var(--fg);
  color: white;
}
.btn-primary:hover { transform: translateY(-1px); background: #111827; }

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--fg); }

.btn-sm { padding: 8px 14px; font-size: 13px; }
.btn-lg { padding: 14px 26px; font-size: 16px; }

/* ===== Hero ===== */
.hero {
  padding: 60px 0 40px;
}

.hero-wrap {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 860px) {
  .hero-wrap { grid-template-columns: 1fr; }
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--accent-soft);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 18px;
}

.lede {
  font-size: 18px;
  line-height: 1.6;
  color: var(--muted);
  margin: 1rem 0 2rem;
}

.hero-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.hero-badges {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  color: var(--subtle);
  font-size: 13px;
}

/* Hero visual: demo mock */
.hero-visual .demo {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
/* Hero demo video (animated demo overrides the static mock when present) */
.hero-visual .hero-demo-video {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  background: var(--card);
}
.hero-visual .hero-demo-video img {
  width: 100%;
  display: block;
  border-radius: var(--radius);
}
@media (prefers-reduced-motion: reduce) {
  .hero-visual .hero-demo-video { animation: none; }
  .hero-visual video { display: none; }
  .hero-visual img { display: block; }
}

.demo-head {
  display: flex;
  gap: 6px;
  padding: 10px 14px;
  background: #f1f2f6;
  border-bottom: 1px solid var(--border);
}
.demo-head span {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #d0d5dd;
}
.demo-head span:nth-child(1) { background: #ff5f57; }
.demo-head span:nth-child(2) { background: #febc2e; }
.demo-head span:nth-child(3) { background: #28c840; }

.demo-body {
  padding: 24px 28px 32px;
  min-height: 220px;
  position: relative;
}

#demo-text {
  color: var(--fg);
  font-size: 17px;
  line-height: 1.7;
  margin: 0;
  transition: font-family 0.3s ease, letter-spacing 0.3s ease;
}

.demo-body::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: 60%;
  height: 36px;
  background: #FFE066;
  opacity: 0.35;
  pointer-events: none;
}

/* ===== Strip ===== */
.strip {
  background: var(--accent-soft);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.strip-wrap { padding: 14px 20px; text-align: center; color: var(--muted); font-size: 14px; }

/* ===== Sections ===== */
.section { padding: 80px 0; }
.section.alt { background: var(--card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section h2 { max-width: 700px; }
.section-lede { max-width: 640px; color: var(--muted); font-size: 17px; margin-bottom: 2rem; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  transition: transform 0.12s, box-shadow 0.15s;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }

.card h3 { margin-bottom: 6px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.card kbd {
  background: var(--fg); color: white;
  border-radius: 4px; padding: 1px 6px; font-size: 11px;
  margin: 0 1px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.pro {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 8px;
  letter-spacing: 0.04em;
  vertical-align: middle;
}

.fonts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.font-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
}
.font-card .sample {
  font-size: 22px;
  line-height: 1.4;
  margin: 6px 0 16px;
  color: var(--fg);
}

/* ===== Steps ===== */
.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.steps li {
  counter-increment: step;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  position: relative;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  top: -14px; left: 22px;
  background: var(--fg);
  color: white;
  font-weight: 700;
  width: 28px; height: 28px;
  display: grid; place-items: center;
  border-radius: 50%;
}

/* ===== Checks ===== */
.checks {
  list-style: none;
  padding: 0; margin: 0;
}
.checks li {
  padding: 6px 0 6px 26px;
  position: relative;
  color: var(--muted);
}
.checks li::before {
  content: "✓";
  position: absolute; left: 0;
  color: var(--success);
  font-weight: 700;
}

/* ===== FAQ ===== */
details {
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
}
details summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--fg);
  font-family: "Lexend", sans-serif;
  list-style: none;
}
details summary::-webkit-details-marker { display: none; }
details summary::after {
  content: "+";
  float: right;
  color: var(--subtle);
  transition: transform 0.2s;
}
details[open] summary::after { content: "−"; }
details p { margin-top: 8px; }

/* ===== CTA Final ===== */
.cta-final {
  text-align: center;
  background: linear-gradient(135deg, var(--accent-soft), #fce8ff);
  border-top: 1px solid var(--border);
}
.cta-final h2 { margin: 0 auto; }
.cta-final p { margin: 1rem auto 1.5rem; color: var(--muted); max-width: 520px; }

/* ===== Footer ===== */
.footer { border-top: 1px solid var(--border); padding: 40px 0 24px; background: var(--card); }
.footer-wrap { display: flex; flex-wrap: wrap; gap: 40px; justify-content: space-between; align-items: flex-start; padding: 0 20px; }
.footer nav ul {
  list-style: none; padding: 0; margin: 0;
  display: grid; grid-template-columns: repeat(2, auto); gap: 8px 36px;
}
.footer nav a { color: var(--muted); font-size: 14px; }
.footer nav a:hover { color: var(--accent); }
.subfoot { text-align: center; color: var(--subtle); padding-top: 18px; font-size: 12px; }

/* ===== Pricing page ===== */
.price-hero { padding: 80px 0 40px; text-align: center; }
.price-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  max-width: 720px;
  margin: 2rem auto 0;
}
.price-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 24px;
  text-align: left;
}
.price-card.featured {
  border: 2px solid var(--accent);
  position: relative;
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.price-card.featured::before {
  content: "BEST VALUE";
  position: absolute;
  top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: white;
  padding: 4px 12px; border-radius: 999px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em;
}
.price { font-size: 42px; font-weight: 700; color: var(--fg); font-family: "Lexend", sans-serif; margin: 10px 0 0; }
.price small { font-size: 15px; color: var(--subtle); font-weight: 400; }
.price-card ul { list-style: none; padding: 0; margin: 18px 0; }
.price-card li { padding: 6px 0 6px 24px; position: relative; color: var(--muted); font-size: 15px; }
.price-card li::before { content: "✓"; position: absolute; left: 0; color: var(--success); font-weight: 700; }
.price-card.free li.locked::before { content: "—"; color: var(--subtle); }
.price-card.free li.locked { color: var(--subtle); }
.price-card .btn { width: 100%; justify-content: center; }

/* ===== Content pages (privacy / terms / faq / welcome) ===== */
article.content { padding: 60px 0; }
article.content h1 { margin-bottom: 0.25em; }
article.content h2 { margin-top: 2em; }
article.content p, article.content li { color: var(--muted); }
article.content ul { padding-left: 18px; }

/* ===== Utilities ===== */
.muted { color: var(--muted); }
.center { text-align: center; }

/* =========================================================
   Subpage styles (pro, faq, privacy, terms, welcome, support,
   404, blog index, blog posts) use a parallel set of class
   names. Everything below maps those to the same design.
   ========================================================= */

/* ----- Subpage header (.site-header) ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(253, 252, 249, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  /* override the sticky .nav rule so only the outer .site-header is sticky */
  position: static;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  z-index: auto;
}
.nav-links {
  display: flex;
  gap: 22px;
  align-items: center;
  flex-wrap: wrap;
}
.nav-links a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a.btn { color: var(--fg); }
.nav-links a.btn.btn-primary { color: white; }
.nav-links a[aria-current="page"] { color: var(--accent); font-weight: 600; }

/* ----- Hero (subpage) ----- */
.hero.hero-compact {
  padding: 60px 0 30px;
  text-align: left;
}
.hero.hero-compact .wrap { max-width: var(--max); }
.hero.hero-compact h1 { margin-bottom: 0.5rem; }

/* Trust row — buyer protections row above the fold on /pro */
.trust-row {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}
.trust-row li {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 34px 1fr;
  grid-template-rows: auto auto;
  column-gap: 12px;
  align-items: center;
}
.trust-row .trust-icon {
  grid-row: 1 / span 2;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.trust-row strong {
  font-family: "Lexend", "Atkinson Hyperlegible", sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--fg);
  line-height: 1.25;
}
.trust-row span:not(.trust-icon) {
  font-size: 0.82rem;
  color: var(--subtle);
  line-height: 1.3;
}

/* .lead behaves like the homepage's .lede */
.lead {
  font-size: 18px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0.5rem 0 1.5rem;
  max-width: 680px;
}

/* ----- Article wrapper ----- */
.section.article { padding: 48px 0 64px; }
.section.article h1 { margin-top: 0.25em; }
.section.article h2 { margin-top: 2em; }
.section.article h3 { margin-top: 1.5em; }
.section.article p,
.section.article li { color: var(--muted); }
.section.article ul,
.section.article ol { padding-left: 1.2em; }
.section.article li { margin-bottom: 6px; }
.section.article hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 2.5rem 0 1.5rem;
}
.section.article strong { color: var(--fg); }
.section.article code {
  background: var(--accent-soft);
  color: var(--fg);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.92em;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ----- Inline CTA (blog / article footer) ----- */
.cta-inline {
  margin: 2rem 0 1rem;
  text-align: center;
}

/* ----- Post meta line ----- */
.post-meta {
  color: var(--subtle);
  font-size: 14px;
  margin-top: 0.5rem;
}
.post-meta a { color: var(--accent); }

/* ----- Blog index cards ----- */
.post-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 26px;
  margin-bottom: 18px;
  transition: transform 0.12s, box-shadow 0.15s;
}
.post-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.post-card h2 { font-size: 1.4rem; margin: 0 0 0.5rem; }
.post-card h2 a { color: var(--fg); }
.post-card h2 a:hover { color: var(--accent); text-decoration: none; }
.post-card p { margin: 0 0 0.4rem; color: var(--muted); }

/* ----- Pricing page (pro.html) ----- */
.pricing { padding: 20px 0 60px; }
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
  max-width: 820px;
  margin: 0 auto;
}
.price-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px;
  position: relative;
  display: flex;
  flex-direction: column;
}
.price-card h2 {
  font-size: 1.3rem;
  margin: 0 0 6px;
  font-family: "Lexend", sans-serif;
}
.price-card .price {
  font-size: 40px;
  font-weight: 700;
  color: var(--fg);
  font-family: "Lexend", sans-serif;
  margin: 4px 0 0;
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.price-card .price .amount { font-size: 40px; }
.price-card .price .period {
  font-size: 14px;
  color: var(--subtle);
  font-weight: 400;
}
.price-card .sub-price {
  color: var(--subtle);
  font-size: 13px;
  margin: 4px 0 10px;
}
.price-card .checks { margin: 16px 0 20px; }
.price-card .btn { width: 100%; justify-content: center; }
.price-card .fine-print {
  color: var(--subtle);
  font-size: 12.5px;
  margin: 12px 0 0;
  text-align: center;
}
.price-card--featured {
  border: 2px solid var(--accent);
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}
.price-card--featured .badge {
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: white;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.btn-block { width: 100%; justify-content: center; }

/* ----- Pricing-page alt section ----- */
.section.section--alt {
  background: var(--card);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* ----- Details (collapsible FAQs on subpages) ----- */
details.faq {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 20px;
  margin-bottom: 10px;
}
details.faq summary {
  font-weight: 600;
  color: var(--fg);
  font-family: "Lexend", sans-serif;
  cursor: pointer;
  list-style: none;
  padding: 4px 0;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: "+";
  float: right;
  color: var(--subtle);
  font-weight: 700;
  transition: transform 0.2s;
}
details.faq[open] summary::after { content: "−"; }
details.faq p { color: var(--muted); margin: 10px 0 4px; }

/* ----- Final CTA section (.cta) on subpages ----- */
.cta {
  padding: 80px 0;
  text-align: center;
  background: linear-gradient(135deg, var(--accent-soft), #fce8ff);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.cta h2 { margin: 0 auto 0.75rem; max-width: 640px; }
.cta p { margin: 0 auto 1.5rem; color: var(--muted); max-width: 520px; }

/* ----- Subpage footer (.site-footer) ----- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 24px;
  background: var(--card);
}
.site-footer .footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 32px;
  align-items: start;
}
@media (max-width: 720px) {
  .site-footer .footer-grid { grid-template-columns: 1fr 1fr; }
}
.site-footer strong {
  font-family: "Lexend", sans-serif;
  font-size: 16px;
  display: block;
  margin-bottom: 6px;
  color: var(--fg);
}
.site-footer p { color: var(--muted); font-size: 14px; margin: 0 0 0.5rem; }
.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.site-footer ul li a { color: var(--muted); font-size: 14px; text-decoration: none; }
.site-footer ul li a:hover { color: var(--accent); }
.site-footer .copy {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--subtle);
  font-size: 12.5px;
  padding-top: 18px;
  margin: 0;
  border-top: 1px solid var(--border);
  margin-top: 16px;
}
