/* Long-form pages: whitepaper, thesis, about */
.lf-hero { min-height: 520px; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.lf-hero .ctas { display: flex; gap: 10px; justify-content: center; margin-top: 28px; flex-wrap: wrap; }
.lf-meta { display: flex; gap: 18px; justify-content: center; margin-top: 22px; font-size: 13px; color: var(--text-3); flex-wrap: wrap; }
.lf-meta span { display: inline-flex; gap: 8px; align-items: center; }

/* reading progress */
.read-progress { position: fixed; top: 68px; left: 0; right: 0; height: 2px; z-index: 90; background: var(--accent); transform-origin: left; transform: scaleX(0); }

/* whitepaper */
.wp { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); max-width: 1240px; margin: 0 auto; padding: 60px var(--x) 120px; }
.wp-index { position: sticky; top: 92px; align-self: start; font-size: 14px; }
.wp-index h5 { font-weight: 400; font-size: 11px; color: var(--text-3); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 12px; }
.wp-index a { display: grid; grid-template-columns: 28px 1fr; gap: 6px; padding: 7px 10px; color: var(--text-3); border-left: 1px solid var(--edge); }
.wp-index a span { font: 12px "IBM Plex Mono", monospace; }
.wp-index a:hover { color: var(--text); }
.wp-index a.on { color: var(--text); border-left-color: var(--accent); background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 6%, transparent), transparent); }
.wp-index a.on span { color: var(--accent); }
.wp-index .btn { margin-top: 18px; width: 100%; justify-content: center; }
.wp-sec { scroll-margin-top: 90px; padding-bottom: 40px; margin-bottom: 40px; border-bottom: 1px solid var(--line); }
.wp-sec:last-of-type { border-bottom: 0; }
.wp-sec .num { font: 12px "IBM Plex Mono", monospace; color: var(--accent); display: block; margin-bottom: 10px; }
.wp-sec h2 { margin-top: 0 !important; }
.fig { margin: 26px 0 30px; border: 1px solid var(--edge); background: var(--surface); padding: 18px; }
.fig svg { display: block; width: 100%; height: auto; }
.fig figcaption { font-size: 13px; color: var(--text-3); margin-top: 12px; }
.fig text { font-family: "IBM Plex Sans", sans-serif; }
.abstract { border: 1px solid var(--edge-2); border-left: 2px solid var(--accent); padding: 20px 22px; background: var(--surface); font-size: 18px; color: var(--text); }

/* thesis */
.essay { padding: 70px var(--x) 120px; }
.essay .prose > p:first-of-type::first-letter { float: left; font-size: 64px; line-height: .9; padding: 6px 10px 0 0; color: var(--accent); }
.pull { margin: 46px -40px; padding: 28px 40px; border-top: 1px solid var(--edge-2); border-bottom: 1px solid var(--edge-2); font-size: clamp(24px, 2.6vw, 34px); line-height: 1.25; letter-spacing: -.02em; color: var(--text); position: relative; }
.pull::before { content: ""; position: absolute; left: 0; top: -1px; width: 80px; height: 2px; background: var(--k, var(--violet)); }
.pull cite { display: block; font-size: 13px; font-style: normal; color: var(--text-3); margin-top: 12px; letter-spacing: 0; }
.compare { margin: 30px 0; }
.compare td:nth-child(2) { color: var(--danger); }
.compare td:nth-child(3) { color: var(--accent); }
.compare .tbl td { font-size: 14px; }
.cta-band { text-align: center; padding: 90px var(--x); position: relative; overflow: hidden; border-top: 1px solid var(--line); }
.cta-band h2 { font-size: clamp(36px, 4.4vw, 64px); }
.cta-band p { color: var(--text-2); margin: 16px auto 0; max-width: 52ch; }
.cta-band .ctas { display: flex; gap: 10px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
.cta-band canvas { opacity: .7; }
.cta-band > *:not(canvas) { position: relative; z-index: 1; }

/* about */
.prod-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.prod { border: 1px solid var(--edge); background: var(--card); display: flex; flex-direction: column; transition: border-color .2s, transform .3s var(--ease); }
.prod:hover { border-color: var(--edge-3); transform: translateY(-3px); }
.prod .art { position: relative; height: 170px; background: var(--surface); border-bottom: 1px solid var(--edge); }
.prod .txt { padding: 16px 18px 20px; }
.prod h3 { font-weight: 400; font-size: 19px; display: flex; gap: 8px; align-items: center; }
.prod p { font-size: 13px; color: var(--text-2); margin-top: 6px; line-height: 1.55; }
.prod .go { font-size: 12px; margin-top: 12px; display: inline-block; }
.prod.soon { opacity: .7; }
.numbers { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--edge); }
.numbers > div { padding: 28px; background: var(--card); }
.numbers > div + div { border-left: 1px solid var(--edge); }
.numbers b { display: block; font-size: clamp(44px, 5vw, 72px); font-weight: 400; letter-spacing: -.05em; line-height: 1; }
.numbers small { display: block; font-size: 13px; color: var(--text-2); margin-top: 10px; }
.principles { counter-reset: p; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.principles .card::before { counter-increment: p; content: "0" counter(p); display: block; font: 12px "IBM Plex Mono", monospace; color: var(--accent); margin-bottom: 18px; }
.contact-row { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 24px; }
.sec-head { text-align: center; max-width: 860px; margin: 0 auto 44px; }
.sec-head h2 { font-size: clamp(32px, 3.6vw, 56px); }
.sec-head h2 em { font-style: normal; }
.sec-head p { color: var(--text-2); font-size: var(--t-lead); margin-top: 16px; line-height: 1.55; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 64px); align-items: center; }
.split .art { position: relative; height: 380px; border: 1px solid var(--edge); background: var(--surface); }

@media (max-width: 1100px) { .prod-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) {
  .wp { grid-template-columns: 1fr; }
  .wp-index { position: static; border: 1px solid var(--edge); padding: 14px; background: var(--card); }
  .numbers { grid-template-columns: 1fr 1fr; } .numbers > div:nth-child(3) { border-left: 0; } .numbers > div:nth-child(n+3) { border-top: 1px solid var(--edge); }
  .principles, .split { grid-template-columns: 1fr; }
  .prod-grid { grid-template-columns: 1fr 1fr; }
  .pull { margin: 36px 0; padding: 22px 0; }
}
@media (max-width: 520px) { .prod-grid { grid-template-columns: 1fr; } .numbers { grid-template-columns: 1fr; } .numbers > div + div { border-left: 0; border-top: 1px solid var(--edge); } }

@media print {
  @page { margin: 18mm 16mm; }
  html, body { background: #fff !important; color: #111 !important; }
  .read-progress, .wp-index, .page-hero canvas, .cta-band, .no-print, #glim-toasts { display: none !important; }
  .page-hero { min-height: 0; padding: 0 0 18px; border: 0; text-align: left; }
  .page-hero::after { display: none; }
  .page-hero h1, .page-hero h1 em { color: #111 !important; font-size: 34px; }
  .page-hero p, .lf-meta { color: #444 !important; margin-left: 0; justify-content: flex-start; }
  .eyebrow, .eyebrow .sub { color: #555 !important; }
  .wp { display: block; padding: 0; }
  .wp-sec { break-before: page; border: 0; }
  .wp-sec:first-of-type { break-before: auto; }
  .prose, .prose p, .prose li, .prose h2, .prose h3, .prose td { color: #111 !important; }
  .prose th { color: #555 !important; }
  .prose td, .prose th { border-color: #ccc !important; }
  .prose code { background: #f2f2f2; color: #222; border-color: #ddd; }
  .wp-sec .num { color: #555; }
  .abstract { background: #f7f7f7; color: #111; border-color: #ccc; }
  .fig { background: #0a0a0c; break-inside: avoid; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .fig figcaption { color: #888; }
  a { border: 0 !important; color: #111 !important; }
}
.prose h2[id], .prose h3[id] { scroll-margin-top: 90px; }
