/* Catalyx — research pages. Same tokens as the landing page:
   ink #17201f · deep #10201e · teal #0e4f4a · mint #7fb5ac · copper #c96f4a · cream #faf9f6 · sand #f2f0ea */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: #faf9f6; color: #17201f; font-family: 'Inter', 'Helvetica Neue', Arial, sans-serif; font-size: 16px; letter-spacing: -0.006em; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
a { color: inherit; text-decoration: none; transition: color .25s ease, background-color .25s ease, border-color .25s ease, transform .25s ease; }
h1, h2, h3 { margin: 0; font-family: 'Space Grotesk', 'Inter', sans-serif; font-weight: 300; }
p { margin: 0; }
::selection { background: #d8e8e5; color: #10201e; }
:focus-visible { outline: 2px solid #7fb5ac; outline-offset: 3px; border-radius: 2px; }
:focus:not(:focus-visible) { outline: none; }

.cx-wrap { max-width: 1240px; margin: 0 auto; padding: 0 40px; }
.cx-label { font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: #0e4f4a; }
.cx-mono { font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(23,32,31,0.48); }
.cx-bracket { color: #c96f4a; font-weight: 400; }
.cx-btn { display: inline-flex; align-items: center; gap: 10px; height: 50px; padding: 0 28px; border-radius: 4px; font-size: 14.5px; font-weight: 500; white-space: nowrap; }
.cx-btn-primary { background: #0e4f4a; color: #f5f4ef; box-shadow: 0 1px 2px rgba(8,14,13,.14); }
.cx-btn-primary:hover { background: #17201f; transform: translateY(-2px); box-shadow: 0 12px 28px rgba(14,79,74,.28); }
.cx-btn-ghost { padding: 0 4px; border-bottom: 1px solid rgba(23,32,31,0.28); border-radius: 0; height: 48px; }
.cx-btn-ghost:hover { color: #0e4f4a; border-bottom-color: #0e4f4a; }

/* ── nav ── */
#top { position: sticky; top: 0; z-index: 50; background: rgba(250,249,246,0.86); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid rgba(23,32,31,0.08); }
#cx-nav { max-width: 1240px; margin: 0 auto; padding: 0 40px; height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.cx-brand { display: flex; align-items: center; gap: 12px; }
.cx-brand-name { font-family: 'Space Grotesk', sans-serif; font-size: 18px; font-weight: 600; letter-spacing: -0.01em; color: #17201f; line-height: 1; }
.cx-brand-sub { display: block; margin-top: 3px; font-family: 'JetBrains Mono', monospace; font-size: 9px; letter-spacing: 0.24em; color: rgba(23,32,31,0.5); text-transform: uppercase; }
.cx-navlinks { display: flex; align-items: center; gap: 36px; font-size: 13.5px; }
.cx-navlink { position: relative; padding-bottom: 3px; color: rgba(23,32,31,0.72); }
.cx-navlink::after { content: ''; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%; background: #0e4f4a; transform: scaleX(0); transform-origin: right; transition: transform .4s cubic-bezier(.22,.61,.21,1); }
.cx-navlink:hover, .cx-navlink.cx-active { color: #17201f; }
.cx-navlink:hover::after, .cx-navlink.cx-active::after { transform: scaleX(1); transform-origin: left; }
.cx-nav-cta { height: 38px; padding: 0 20px; font-size: 13px; }

/* ── research index ── */
.cx-hero-r { padding: 104px 0 72px; }
.cx-hero-r h1 { margin-top: 22px; font-size: clamp(44px, 5.6vw, 76px); line-height: 1.0; letter-spacing: -0.03em; text-wrap: balance; max-width: 900px; }
.cx-hero-r h1 em { font-style: normal; font-weight: 500; }
.cx-hero-r p { margin-top: 26px; max-width: 520px; font-size: 17px; line-height: 1.6; color: rgba(23,32,31,0.62); }
.cx-notes { border-top: 1px solid rgba(23,32,31,0.12); }
.cx-note { display: grid; grid-template-columns: 210px minmax(0, 1fr) 40px; gap: 40px; align-items: start; padding: 44px 0; border-bottom: 1px solid rgba(23,32,31,0.12); }
.cx-note:hover h2 { color: #0e4f4a; }
.cx-note h2 { font-size: clamp(26px, 2.6vw, 34px); font-weight: 400; line-height: 1.15; letter-spacing: -0.02em; transition: color .25s ease; }
.cx-note p { margin-top: 12px; max-width: 640px; font-size: 15.5px; line-height: 1.6; color: rgba(23,32,31,0.62); }
.cx-note .cx-mono { display: block; line-height: 1.9; padding-top: 6px; }
.cx-note .cx-mono b { display: block; font-weight: 500; color: #0e4f4a; }
.cx-note .cx-arrow { font-family: 'Space Grotesk', sans-serif; font-size: 26px; color: rgba(23,32,31,0.3); padding-top: 4px; transition: transform .3s cubic-bezier(.22,.61,.21,1), color .25s ease; }
.cx-note:hover .cx-arrow { transform: translateX(6px); color: #0e4f4a; }
.cx-soon { padding: 36px 0 120px; font-size: 14px; color: rgba(23,32,31,0.5); }

/* ── article ── */
.cx-article-head { padding: 88px 0 56px; border-bottom: 1px solid rgba(23,32,31,0.12); }
.cx-article-head .cx-crumb { display: flex; gap: 10px; align-items: center; }
.cx-article-head .cx-crumb a:hover { color: #0e4f4a; }
.cx-article-head h1 { margin-top: 26px; max-width: 900px; font-size: clamp(38px, 4.8vw, 66px); line-height: 1.02; letter-spacing: -0.03em; text-wrap: balance; }
.cx-article-head h1 em { font-style: normal; font-weight: 500; }
.cx-standfirst { margin-top: 24px; max-width: 680px; font-size: 19px; line-height: 1.55; color: rgba(23,32,31,0.65); }
.cx-meta { display: flex; flex-wrap: wrap; gap: 12px 36px; margin-top: 36px; }
.cx-meta .cx-mono b { display: block; margin-top: 4px; font-weight: 500; color: #17201f; letter-spacing: 0.04em; font-size: 12px; }

.cx-article { display: grid; grid-template-columns: minmax(0, 720px) 280px; gap: 96px; justify-content: space-between; padding: 64px 0 120px; }
.cx-prose { font-size: 17px; line-height: 1.7; color: rgba(23,32,31,0.82); }
.cx-prose h2 { margin: 56px 0 18px; font-size: 30px; font-weight: 400; letter-spacing: -0.02em; line-height: 1.15; color: #17201f; }
.cx-prose h2:first-child { margin-top: 0; }
.cx-prose h2 .cx-mono { display: block; margin-bottom: 10px; color: #0e4f4a; }
.cx-prose h3 { margin: 32px 0 10px; font-size: 20px; font-weight: 500; letter-spacing: -0.01em; color: #17201f; }
.cx-prose p { margin: 0 0 20px; }
.cx-prose p:last-child { margin-bottom: 0; }
.cx-prose ul { margin: 0 0 22px; padding-left: 22px; }
.cx-prose li { margin-bottom: 8px; }
.cx-prose li::marker { color: #0e4f4a; }
.cx-prose strong { font-weight: 500; color: #17201f; }
.cx-prose code { font-family: 'JetBrains Mono', monospace; font-size: 14px; padding: 2px 6px; border-radius: 3px; background: #f2f0ea; color: #0e4f4a; }
.cx-prose a { color: #0e4f4a; border-bottom: 1px solid rgba(14,79,74,0.3); }
.cx-prose a:hover { border-bottom-color: #0e4f4a; }

.cx-summary { margin: 0 0 8px; padding: 26px 30px; border: 1px solid rgba(23,32,31,0.12); border-left: 2px solid #0e4f4a; border-radius: 0 6px 6px 0; background: #f2f0ea; }
.cx-summary .cx-mono { display: block; margin-bottom: 12px; color: #0e4f4a; }
.cx-summary ul { margin: 0; padding-left: 20px; font-size: 16px; line-height: 1.6; }
.cx-summary li { margin-bottom: 8px; }
.cx-summary li:last-child { margin-bottom: 0; }

.cx-eq { margin: 26px 0 28px; padding: 24px 28px; border: 1px solid rgba(23,32,31,0.12); border-radius: 6px; background: #fff; }
.cx-eq .cx-mono { display: block; margin-bottom: 12px; }
.cx-eq .cx-math { font-family: 'Newsreader', Georgia, 'Times New Roman', serif; font-style: italic; font-size: 22px; line-height: 1.6; color: #17201f; overflow-x: auto; }
.cx-eq .cx-math b { font-style: normal; font-weight: 400; }
.cx-eq .cx-math sub, .cx-eq .cx-math sup { font-size: 13px; }
.cx-eq .cx-where { margin-top: 12px; font-size: 14px; line-height: 1.65; color: rgba(23,32,31,0.6); }

.cx-fig { margin: 30px 0 34px; }
.cx-fig svg { display: block; width: 100%; height: auto; border: 1px solid rgba(23,32,31,0.12); border-radius: 6px; background: #fff; }
.cx-fig figcaption { margin-top: 12px; font-size: 13.5px; line-height: 1.55; color: rgba(23,32,31,0.55); }
.cx-fig figcaption b { font-weight: 500; color: #17201f; }

.cx-table { width: 100%; border-collapse: collapse; margin: 22px 0 30px; font-size: 15px; }
.cx-table th { text-align: left; padding: 10px 14px 12px 0; font-family: 'JetBrains Mono', monospace; font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(23,32,31,0.48); font-weight: 500; border-bottom: 1px solid #17201f; }
.cx-table td { padding: 12px 14px 12px 0; border-bottom: 1px solid rgba(23,32,31,0.1); vertical-align: top; line-height: 1.5; }
.cx-table td.cx-num { font-family: 'JetBrains Mono', monospace; font-size: 14px; white-space: nowrap; }
.cx-table td.cx-num.cx-good { color: #0e4f4a; font-weight: 500; }
.cx-table td.cx-num.cx-bad { color: #c96f4a; }
.cx-table-wrap { overflow-x: auto; }

.cx-callout { margin: 30px 0; padding: 22px 26px; border-radius: 6px; background: #10201e; color: #ecebe4; font-size: 15.5px; line-height: 1.6; }
.cx-callout .cx-mono { display: block; margin-bottom: 8px; color: #7fb5ac; }

/* sidebar */
.cx-side { position: sticky; top: 96px; align-self: start; display: flex; flex-direction: column; gap: 32px; }
.cx-side .cx-mono { display: block; margin-bottom: 12px; }
.cx-toc { display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; }
.cx-toc a { padding: 6px 0 6px 14px; border-left: 1px solid rgba(23,32,31,0.12); color: rgba(23,32,31,0.62); }
.cx-toc a:hover { color: #17201f; border-left-color: #0e4f4a; }
.cx-side-box { padding: 18px 20px; border: 1px solid rgba(23,32,31,0.12); border-radius: 6px; font-size: 13.5px; line-height: 1.6; color: rgba(23,32,31,0.65); }
.cx-side-box b { display: block; font-weight: 500; color: #17201f; font-size: 14px; margin-bottom: 4px; }
.cx-side-box .cx-btn { margin-top: 14px; height: 42px; padding: 0 18px; font-size: 13px; }

/* next note */
.cx-next { border-top: 1px solid rgba(23,32,31,0.12); background: #f2f0ea; }
.cx-next .cx-wrap { display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap; padding-top: 44px; padding-bottom: 44px; }
.cx-next h2 { font-size: 24px; font-weight: 400; letter-spacing: -0.02em; margin-top: 8px; }
.cx-next a:hover h2 { color: #0e4f4a; }

/* footer */
.cx-foot { background: #10201e; color: #ecebe4; }
.cx-foot .cx-wrap { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; flex-wrap: wrap; padding-top: 48px; padding-bottom: 44px; }
.cx-foot-links { display: flex; gap: 28px; font-size: 13px; }
.cx-foot-links a { color: rgba(236,235,228,0.62); }
.cx-foot-links a:hover { color: #f5f4ef; }

@media (max-width: 1024px) {
  .cx-article { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .cx-side { position: static; }
  .cx-toc { display: none; }
}
@media (max-width: 860px) {
  .cx-navlinks { display: none; }
  .cx-wrap, #cx-nav { padding-left: 24px; padding-right: 24px; }
  .cx-hero-r { padding: 72px 0 48px; }
  .cx-note { grid-template-columns: 1fr; gap: 14px; padding: 32px 0; }
  .cx-note .cx-arrow { display: none; }
  .cx-article-head { padding: 56px 0 40px; }
  .cx-article { padding: 44px 0 80px; }
  .cx-prose { font-size: 16px; }
  .cx-prose h2 { font-size: 26px; margin-top: 44px; }
  .cx-eq { padding: 18px 20px; }
  .cx-eq .cx-math { font-size: 19px; }
}
@media (max-width: 520px) {
  .cx-wrap, #cx-nav { padding-left: 18px; padding-right: 18px; }
  .cx-nav-cta { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .001ms !important; }
}
