/* ─────────────────────────────────────────────────────────
   longform.naviplus.io — modern editorial design
   ───────────────────────────────────────────────────────── */
:root {
  --ink: #15171c;
  --ink-soft: #51566177;
  --muted: #5b616e;
  --line: #e7e8ee;
  --bg: #ffffff;
  --bg-soft: #f7f7fb;
  --brand: #2f7d5b;
  --brand-2: #6d5cf0;
  --hero: #6d5cf0;
  --radius: 18px;
  --wrap: 1120px;
  --shadow: 0 1px 2px rgba(16,17,23,.05), 0 12px 32px -12px rgba(16,17,23,.12);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased;
}
a { color: var(--brand); text-decoration: none; }
img { max-width: 100%; }
.lf-wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

/* ── Header ───────────────────────────────────────────── */
.lf-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.82); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.lf-nav {
  max-width: var(--wrap); margin: 0 auto; padding: 0 24px;
  height: 62px; display: flex; align-items: center; gap: 18px;
}
.lf-logo { display: flex; align-items: center; gap: 8px; }
.lf-logo img { height: 26px; width: auto; }
.lf-logo-tag {
  font-family: "Fraunces", serif; font-weight: 600; font-size: 17px;
  color: var(--ink); letter-spacing: -.01em;
}
.lf-nav-link { color: var(--muted); font-weight: 500; font-size: 14px; }
.lf-nav-link:hover { color: var(--ink); }
.lf-nav-spacer { flex: 1; }
.lf-nav-cta {
  font-weight: 600; font-size: 14px; color: #fff;
  background: var(--ink); padding: 8px 14px; border-radius: 10px;
}
.lf-nav-cta:hover { background: #000; }

/* Language switcher */
.lf-lang { position: relative; }
.lf-lang-btn {
  display: flex; align-items: center; gap: 6px;
  background: none; border: 1px solid var(--line); border-radius: 10px;
  padding: 6px 10px; font: inherit; font-size: 13px; font-weight: 600;
  color: var(--muted); cursor: pointer;
}
.lf-lang-btn:hover { color: var(--ink); border-color: #d2d4de; }
.lf-lang-menu {
  position: absolute; right: 0; top: calc(100% + 8px);
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow); padding: 6px; min-width: 88px;
  display: none; grid-template-columns: 1fr 1fr; gap: 2px;
}
.lf-lang:hover .lf-lang-menu, .lf-lang:focus-within .lf-lang-menu { display: grid; }
.lf-lang-item {
  text-align: center; font-size: 13px; font-weight: 600; color: var(--muted);
  padding: 6px 8px; border-radius: 8px;
}
.lf-lang-item:hover { background: var(--bg-soft); color: var(--ink); }
.lf-lang-item.is-active { color: var(--brand); background: #eef6f1; }

/* ── Hero (home) ──────────────────────────────────────── */
.lf-hero { padding: 78px 0 38px; text-align: center;
  background:
    radial-gradient(60% 120% at 50% -10%, #eef0ff 0%, transparent 60%),
    radial-gradient(40% 90% at 90% 0%, #eafaf2 0%, transparent 55%);
}
.lf-hero-badge {
  display: inline-block; font-size: 13px; font-weight: 600; color: var(--brand);
  background: #eef6f1; border: 1px solid #d6eade; border-radius: 999px;
  padding: 5px 14px; margin-bottom: 20px;
}
.lf-hero-title {
  font-family: "Fraunces", serif; font-weight: 600;
  font-size: clamp(34px, 5.4vw, 60px); line-height: 1.05; letter-spacing: -.02em;
  margin: 0 auto 18px; max-width: 16ch;
}
.lf-hero-sub { font-size: clamp(16px,2.1vw,20px); color: var(--muted); max-width: 60ch; margin: 0 auto; }

/* ── Guide grid (home) ────────────────────────────────── */
.lf-guides { padding: 30px 0 80px; }
.lf-section-label {
  font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-soft); margin: 0 0 20px;
}
.lf-guide-grid {
  display: grid; gap: 22px;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
}
.lf-guide-card {
  position: relative; display: flex; flex-direction: column;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; min-height: 230px; overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  color: var(--ink);
}
.lf-guide-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 5px;
  background: linear-gradient(90deg, var(--hero), color-mix(in srgb, var(--hero) 40%, #fff));
}
.lf-guide-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.lf-guide-card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.lf-guide-read { font-size: 13px; color: var(--ink-soft); font-weight: 500; }
.lf-guide-title {
  font-family: "Fraunces", serif; font-weight: 600; font-size: 24px; line-height: 1.2;
  letter-spacing: -.01em; margin: 0 0 10px;
}
.lf-guide-desc { color: var(--muted); font-size: 15.5px; margin: 0 0 18px; flex: 1; }
.lf-guide-link { font-weight: 600; font-size: 14.5px; color: var(--brand); }

.lf-tag {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; color: var(--hero);
  background: color-mix(in srgb, var(--hero) 12%, #fff);
  padding: 4px 10px; border-radius: 999px;
}

/* ── Article ──────────────────────────────────────────── */
.lf-article-hero {
  padding: 54px 0 40px;
  background:
    radial-gradient(70% 120% at 12% -10%, color-mix(in srgb, var(--hero) 16%, #fff) 0%, transparent 60%),
    var(--bg-soft);
  border-bottom: 1px solid var(--line);
}
.lf-crumb { font-size: 14px; font-weight: 600; color: var(--muted); }
.lf-crumb:hover { color: var(--ink); }
.lf-article-hero .lf-tag { margin: 18px 0 0; }
.lf-article-title {
  font-family: "Fraunces", serif; font-weight: 600;
  font-size: clamp(30px, 4.6vw, 50px); line-height: 1.08; letter-spacing: -.02em;
  margin: 14px 0 16px; max-width: 20ch;
}
.lf-article-lede { font-size: clamp(17px,2.2vw,21px); color: var(--muted); max-width: 64ch; margin: 0; }
.lf-article-meta { display: flex; gap: 18px; margin-top: 22px; font-size: 14px; color: var(--ink-soft); font-weight: 500; }
.lf-article-meta span { position: relative; }
.lf-article-meta span + span::before { content: "·"; position: absolute; left: -11px; }

.lf-article-body { padding: 46px 24px 0; }
.lf-prose { max-width: 720px; margin: 0 auto; }
.lf-prose > * { margin-left: auto; margin-right: auto; max-width: 720px; }
.lf-prose h2 {
  font-family: "Fraunces", serif; font-weight: 600; font-size: 30px; line-height: 1.18;
  letter-spacing: -.01em; margin: 48px 0 14px;
}
.lf-prose h3 { font-weight: 700; font-size: 21px; margin: 32px 0 10px; }
.lf-prose p { margin: 0 0 18px; }
.lf-prose ul, .lf-prose ol { margin: 0 0 18px; padding-left: 22px; }
.lf-prose li { margin: 6px 0; }
.lf-prose a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
.lf-prose blockquote {
  margin: 26px 0; padding: 14px 22px; border-left: 4px solid var(--hero);
  background: var(--bg-soft); border-radius: 0 12px 12px 0; color: var(--ink); font-size: 17px;
}
.lf-prose img { border-radius: 12px; }
.lf-prose code { background: var(--bg-soft); padding: 2px 6px; border-radius: 6px; font-size: .9em; }

/* Inline "read the full deep-dive" link at the end of each topic section */
.lf-readmore {
  margin: 18px auto 40px !important; padding: 14px 18px;
  border: 1px solid var(--line); border-left: 4px solid var(--hero);
  border-radius: 0 12px 12px 0; background: var(--bg-soft);
  font-weight: 600;
}
.lf-readmore a { color: var(--brand); text-decoration: none; }
.lf-readmore a:hover { text-decoration: underline; }
.lf-readmore .lf-readmore-kicker {
  display: block; font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--ink-soft); margin-bottom: 2px;
}

/* Explore (child links) */
.lf-explore { max-width: 920px; margin: 60px auto 0; }
.lf-explore h2 { font-family: "Fraunces", serif; font-weight: 600; font-size: 27px; margin: 0 0 6px; }
.lf-explore-sub { color: var(--muted); margin: 0 0 22px; }
.lf-explore-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px,1fr)); }
.lf-explore-card {
  display: flex; flex-direction: column; gap: 4px;
  border: 1px solid var(--line); border-radius: 14px; padding: 18px 18px 18px 44px;
  position: relative; color: var(--ink); transition: border-color .15s, background .15s;
}
.lf-explore-card:hover { border-color: var(--hero); background: var(--bg-soft); }
.lf-explore-arrow { position: absolute; left: 18px; top: 18px; color: var(--hero); font-weight: 700; }
.lf-explore-title { font-weight: 600; font-size: 16px; }
.lf-explore-desc { font-size: 14px; color: var(--muted); }

/* Share */
.lf-share {
  max-width: 720px; margin: 56px auto 0; padding: 18px 0 0; border-top: 1px solid var(--line);
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.lf-share span:first-child { font-weight: 700; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.lf-share a, .lf-copy {
  font-size: 14px; font-weight: 600; color: var(--muted);
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px;
  background: none; cursor: pointer; font-family: inherit;
}
.lf-share a:hover, .lf-copy:hover { color: var(--ink); border-color: #d2d4de; }

/* Backlink (topic → parent) */
.lf-backlink { max-width: 720px; margin: 40px auto 0; padding: 20px 22px;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: 14px; }
.lf-backlink a { font-weight: 600; }
.lf-topic-parent { color: var(--muted); font-size: 14px; margin: 16px 0 0; }

/* CTA */
.lf-cta {
  margin-top: 80px; padding: 64px 0; text-align: center;
  background: linear-gradient(180deg, #0f1117, #1a1d27); color: #fff;
}
.lf-cta h2 { font-family: "Fraunces", serif; font-weight: 600; font-size: clamp(26px,3.6vw,38px); margin: 0 0 10px; color: #fff; }
.lf-cta p { color: #b9bdc9; max-width: 52ch; margin: 0 auto 26px; }
.lf-cta-btn { display: inline-block; background: #fff; color: var(--ink); font-weight: 700; padding: 13px 26px; border-radius: 12px; }
.lf-cta-btn:hover { transform: translateY(-2px); }

/* ── Footer ───────────────────────────────────────────── */
.lf-footer { border-top: 1px solid var(--line); padding: 36px 0; margin-top: 0; }
.lf-footer-inner { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 16px; }
.lf-footer-inner img { height: 22px; }
.lf-footer-note { color: var(--ink-soft); font-size: 14px; margin: 0; }

/* topic head spacing */
.lf-topic-head { padding-top: 40px; }

@media (max-width: 640px) {
  body { font-size: 16px; }
  .lf-nav { gap: 12px; }
  .lf-nav-link { display: none; }
  .lf-article-body { padding-top: 32px; }
  .lf-prose h2 { font-size: 25px; }
}
