/* longform.css — long-form articles, location pages and the blog hub (2026-10-09).
   Loaded only by pages generated with build_longform.py. Uses the tokens in style.css. */

/* ── header ─────────────────────────────────────────── */
.lf-head { padding: 40px 0 0; background: linear-gradient(180deg, var(--bg-tint) 0%, var(--bg) 100%); }
.lf-head-inner { max-width: 880px; }
.lf-crumbs { font-size: 13px; color: var(--text-muted); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.lf-crumbs a { color: var(--text-muted); text-decoration: none; }
.lf-crumbs a:hover { color: var(--accent); }
.lf-crumbs span { color: var(--text-faint); }
.lf-crumbs span[aria-current] { color: var(--text); }
.lf-kind { margin-top: 22px; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.lf-title { margin-top: 12px; font-size: 44px; line-height: 1.12; letter-spacing: -0.025em; font-weight: 800; color: var(--text); }
.lf-excerpt { margin-top: 18px; font-size: 19px; line-height: 1.6; color: var(--text-muted); max-width: 760px; }
.lf-meta { margin-top: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 14px; color: var(--text-muted); }
.lf-meta b { color: var(--text); font-weight: 600; }
.lf-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-faint); }
.lf-avatar { width: 28px; height: 28px; border-radius: 8px; display: inline-block; flex: none; vertical-align: middle; }
.lf-avatar-lg { width: 52px; height: 52px; border-radius: 14px; font-size: 24px; }
.lf-hero { margin-top: 32px; max-width: 1040px; }
.lf-hero img { display: block; width: 100%; height: auto; aspect-ratio: 2/1; object-fit: cover; border-radius: var(--radius-lg); border: 1px solid var(--border); box-shadow: var(--shadow-sm); }

/* ── body grid: sticky TOC + article ─────────────────── */
.lf-shell { padding: 48px 0 72px; }
.lf-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; align-items: start; }
.lf-toc { min-width: 0; position: sticky; top: 96px; max-height: calc(100vh - 120px); overflow: auto; font-size: 13.5px; }
.lf-toc summary { font-weight: 700; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); cursor: pointer; list-style: none; margin-bottom: 12px; }
.lf-toc summary::-webkit-details-marker { display: none; }
.lf-toc ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.lf-toc li { margin: 0; }
.lf-toc a { display: block; padding: 6px 0 6px 14px; margin-left: -1px; border-left: 2px solid transparent; color: var(--text-muted); text-decoration: none; line-height: 1.4; }
.lf-toc a:hover { color: var(--text); }
.lf-toc a.is-active { color: var(--accent); border-left-color: var(--accent); font-weight: 600; }
.lf-toc-cta { margin-top: 20px; }
.lf-prose { max-width: 740px; margin: 0; }
.lf-prose h2 { scroll-margin-top: 96px; }
.lf-prose h3 { scroll-margin-top: 96px; }
.lf-prose a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.lf-prose a.btn { text-decoration: none; }
.lf-prose a.btn-primary { color: #fff; }
.lf-prose ol, .lf-prose ul { margin-left: 22px; }
.lf-partof { font-size: 14px; color: var(--text-muted); margin-bottom: 20px !important; }

.lf-takeaways { background: var(--accent-soft); border: 1px solid #dfe3ff; border-radius: var(--radius-lg); padding: 22px 26px 8px; margin: 0 0 36px; font-size: 16px; }
.lf-takeaways-h { font-size: 12.5px !important; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px !important; }
.lf-takeaways ul { margin: 0 0 14px 20px; }
.lf-takeaways li { margin-bottom: 8px; }

.lf-prose .lf-tip { display: block !important; background: var(--bg-soft); border: 1px solid var(--border); border-left: 3px solid var(--accent-2); border-radius: var(--radius); padding: 16px 20px 2px; margin: 28px 0; font-size: 16px; }
.lf-tip-label { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #0e7490; margin-bottom: 6px; }
.lf-tip p { margin-bottom: 14px; }

.lf-prose .table-wrap { overflow-x: auto; margin: 26px 0 30px; border: 1px solid var(--border); border-radius: var(--radius); }
.lf-prose .data-table { width: 100%; border-collapse: collapse; font-size: 14.5px; line-height: 1.5; }
.lf-prose .data-table th { text-align: left; background: var(--bg-soft); font-weight: 600; padding: 11px 14px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.lf-prose .data-table th, .lf-prose .data-table td { min-width: 96px; }
.lf-prose .data-table td:first-child { min-width: 128px; font-weight: 500; }
.lf-prose .data-table td { padding: 11px 14px; border-bottom: 1px solid var(--border-soft); vertical-align: top; }
.lf-prose .data-table tr:last-child td { border-bottom: 0; }

.lf-figure-inline { margin: 34px 0; }
.lf-figure-inline img { display: block; width: 100%; height: auto; border-radius: var(--radius-lg); border: 1px solid var(--border); }
.lf-figure-inline figcaption { margin-top: 10px; font-size: 13.5px; color: var(--text-muted); text-align: center; }

.lf-faq { margin-top: 56px; }
.lf-faq .faq-item { border: 1px solid var(--border); border-radius: var(--radius); padding: 0; margin-bottom: 10px; background: var(--bg); }
.lf-faq .faq-item summary { padding: 16px 20px; font-weight: 600; font-size: 16.5px; cursor: pointer; list-style: none; }
.lf-faq .faq-item summary::-webkit-details-marker { display: none; }
.lf-faq .faq-body { padding: 0 20px 6px; font-size: 16px; color: var(--text-muted); }

.lf-author { display: flex; gap: 18px; align-items: flex-start; margin-top: 48px; padding: 24px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--bg-soft); font-size: 15px; }
.lf-author p { margin: 0 0 8px; }
.lf-author-name { font-weight: 700; color: var(--text); }

.lf-cta { margin-top: 28px; padding: 30px; border-radius: var(--radius-lg); background: var(--bg-dark); color: var(--text-on-dark); }
.lf-cta p { margin: 0 0 10px; color: #c3c7d4; }
.lf-cta .lf-cta-h { font-size: 22px; font-weight: 700; color: #fff; }
.lf-cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.lf-cta .btn-primary { background: #fff !important; color: var(--text) !important; border-color: #fff !important; }
.lf-cta .btn-ghost { color: #fff !important; border-color: rgba(255,255,255,.3); }

/* ── hub pages ───────────────────────────────────────── */
.lf-hub-head { padding-bottom: 8px; }
.lf-hub { padding-top: 28px; }
.lf-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.lf-chip { appearance: none; border: 1px solid var(--border); background: var(--bg); color: var(--text-muted); font: inherit; font-size: 13.5px; font-weight: 600; padding: 7px 14px; border-radius: 999px; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.lf-chip:hover { border-color: var(--border-strong); color: var(--text); }
.lf-chip.is-on { background: var(--text); border-color: var(--text); color: #fff; }
.lf-group { margin-top: 56px; scroll-margin-top: 96px; }
.lf-group-start { margin-top: 0; }
.lf-group[hidden] { display: none; }
.lf-group-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.lf-group-head a { font-size: 14px; font-weight: 600; color: var(--accent); text-decoration: none; }
.lf-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 24px; }
.lf-cards-pillars { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 24px; }

/* card: the banner is shown at its native 16:9, never cropped */
.lf-card { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg); text-decoration: none; color: inherit; transition: border-color .15s, box-shadow .15s; }
.lf-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow); }
.lf-card img { display: block; width: 100%; height: auto; aspect-ratio: 16/9; object-fit: cover; background: var(--bg-soft); }
.lf-card-body { padding: 18px 20px 18px; display: flex; flex-direction: column; flex: 1; gap: 8px; }
.lf-card-cat { align-self: flex-start; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); padding: 4px 9px; border-radius: 999px; line-height: 1.2; }
.lf-card h3 { font-size: 17px; line-height: 1.3; font-weight: 700; margin: 2px 0 0; color: var(--text); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.lf-card p { font-size: 14px; line-height: 1.55; color: var(--text-muted); margin: 0; flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lf-card-meta { margin-top: 8px; display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; color: var(--text-faint); }
.lf-card-go { font-weight: 600; color: var(--accent); opacity: 0; transform: translateX(-4px); transition: opacity .15s, transform .15s; }
.lf-card:hover .lf-card-go { opacity: 1; transform: none; }

/* featured guide: banner left, copy right */
.lf-card.lf-card-big { flex-direction: row; }
.lf-card.lf-card-big img { width: 58%; aspect-ratio: 16/9; border-right: 1px solid var(--border-soft); }
.lf-card-big .lf-card-body { padding: 36px 40px; justify-content: center; gap: 12px; }
.lf-card-big h3 { font-size: 27px; line-height: 1.18; letter-spacing: -0.015em; -webkit-line-clamp: 4; }
.lf-card-big p { flex: none; font-size: 15.5px; -webkit-line-clamp: 4; }
.lf-card-big .lf-card-go { opacity: 1; transform: none; }

/* related-articles band (shared partial): banner on top, same card language */
.related-band .post-card { display: flex; flex-direction: column; border-radius: var(--radius-lg); transition: border-color .15s, box-shadow .15s; }
.related-band .post-card:hover { transform: none; border-color: var(--border-strong); box-shadow: var(--shadow); }
.related-band .post-card-img { display: block; width: 100%; height: auto; aspect-ratio: 16/9; object-fit: cover; background: var(--bg-soft); }
.related-band .post-card-body { display: flex; flex-direction: column; flex: 1; }
.related-band .post-card .badge { align-self: flex-start; }
.related-band .post-card-title { font-size: 17px; }
.related-band .post-card-summary { flex: 1; }

/* ── responsive ──────────────────────────────────────── */
@media (max-width: 1024px) {
  .lf-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .lf-toc { position: static; max-height: none; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; background: var(--bg-soft); }
  .lf-toc details:not([open]) summary { margin-bottom: 0; }
  .lf-toc .lf-toc-cta { display: none !important; }
  .lf-prose { max-width: none; }
  .lf-cards-pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lf-card.lf-card-big { flex-direction: column; }
  .lf-card.lf-card-big img { width: 100%; border-right: 0; }
  .lf-card-big .lf-card-body { padding: 22px 24px; }
}
@media (max-width: 640px) {
  .lf-head { padding-top: 24px; }
  .lf-chips { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; margin-left: -16px; margin-right: -16px; padding: 0 16px 4px; }
  .lf-chips::-webkit-scrollbar { display: none; }
  .lf-chip { flex: none; }
  .lf-title { font-size: 31px; }
  .lf-excerpt { font-size: 17px; }
  .lf-hero { margin-top: 22px; }
  .lf-shell { padding: 28px 0 56px; }
  .lf-cards-pillars { grid-template-columns: 1fr; }
  .lf-card-big .lf-card-body { padding: 18px 20px 20px; }
  .lf-card-big h3 { font-size: 20px; }
  .lf-author { flex-direction: column; }
  .lf-takeaways { padding: 18px 18px 6px; }
}
.lf-chip-n { display: inline-block; margin-left: 6px; padding: 0 7px; border-radius: 999px; background: rgba(13,18,32,.06); font-size: 12px; font-weight: 700; color: var(--text-muted); }
.lf-chip.is-on .lf-chip-n { background: rgba(255,255,255,.18); color: #fff; }
.lf-card[hidden] { display: none !important; }
