/* Insights - articles and their index. Loaded only by /insights pages, on top of style.css. */
.skip { position: absolute; left: -9999px; top: 8px; z-index: 20; background: var(--text); color: #0b0b0c; padding: 8px 14px; border-radius: 8px; font-weight: 600; }
.skip:focus { left: 16px; }
.links a[aria-current="page"] { color: var(--text); }
a:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* breadcrumb */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 28px 0 0; font-size: 13px; color: var(--faint); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--faint); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.crumbs li[aria-current] { color: var(--muted); max-width: 46ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* index */
.ins-hero { border-bottom: 1px solid var(--line); padding-bottom: 56px;
  background: radial-gradient(900px 420px at 80% 0%, rgba(201, 154, 94, .09), transparent 62%); }
.ins-hero .kicker { margin-top: 56px; }
.ins-hero h1 { font-size: clamp(36px, 4.6vw, 58px); max-width: 860px; }
.ins-hero .sub { margin-bottom: 28px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips a { padding: 7px 14px; border: 1px solid var(--line-2); border-radius: 999px; color: var(--soft); text-decoration: none; font-size: 13.5px; }
.chips a:hover { border-color: rgba(255, 255, 255, .25); color: var(--text); }
.ins-list { padding-top: 24px; padding-bottom: 32px; }
.ins-group { padding-top: 48px; }
.ins-group-h { font: 500 12px/1 "JetBrains Mono", ui-monospace, monospace; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 18px; }
.ins-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.ins-card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 24px 22px; display: flex; flex-direction: column; transition: border-color .15s; }
.ins-card:hover { border-color: rgba(201, 154, 94, .45); }
.ins-card h3, .ins-card h2 { font-size: 19px; line-height: 1.3; margin-bottom: 10px; }
.ins-card h3 a, .ins-card h2 a { text-decoration: none; }
.ins-card h3 a::after, .ins-card h2 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }   /* the whole card is the link */
.ins-cat { font: 500 11.5px/1 "JetBrains Mono", ui-monospace, monospace; color: var(--accent); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 14px; }
.ins-dek { color: var(--muted); font-size: 15px; line-height: 1.55; margin-bottom: 18px; }
.ins-meta { margin: auto 0 0; color: var(--faint); font-size: 13px; }

/* article */
.post-head { padding-top: 36px; padding-bottom: 40px; }
.post-head h1 { font-size: clamp(34px, 4.4vw, 54px); max-width: 920px; }
.post-dek { color: var(--soft); font-size: 19px; line-height: 1.6; max-width: 760px; }
.post-meta { color: var(--faint); font-size: 13.5px; margin: 0; }
.post-grid { display: grid; grid-template-columns: 220px minmax(0, 720px); gap: 64px; padding-bottom: 72px; border-top: 1px solid var(--line); padding-top: 48px; }
.toc { position: sticky; top: 96px; align-self: start; font-size: 13.5px; }
.toc-h { font: 500 11.5px/1 "JetBrains Mono", ui-monospace, monospace; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); margin-bottom: 14px; }
.toc ol { list-style: none; padding: 0; margin: 0; border-left: 1px solid var(--line); }
.toc li a { display: block; padding: 5px 0 5px 14px; color: var(--muted); text-decoration: none; line-height: 1.4; }
.toc li a:hover { color: var(--text); }

.prose { font-size: 17.5px; line-height: 1.75; color: var(--soft); min-width: 0; }
.prose > * + * { margin-top: 0; }
.prose p, .prose ul, .prose ol { margin: 0 0 1.15em; }
.prose h2 { font-size: clamp(24px, 2.4vw, 30px); color: var(--text); margin: 1.9em 0 .6em; scroll-margin-top: 88px; }
.prose > h2:first-child { margin-top: 0; }
.prose h3 { font-size: 19px; color: var(--text); margin: 1.6em 0 .5em; }
.prose a { color: var(--text); text-decoration: underline; text-decoration-color: rgba(201, 154, 94, .6); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: var(--accent); }
.prose .btn { text-decoration: none; color: #0b0b0c; }
.prose .textlink { text-decoration: none; color: var(--soft); }
.prose li { margin-bottom: .45em; }
.prose ul { padding-left: 1.2em; }
.prose ol { padding-left: 1.3em; }
.prose b, .prose strong { color: var(--text); font-weight: 600; }
.prose code { font: 14.5px "JetBrains Mono", ui-monospace, monospace; background: rgba(255, 255, 255, .05); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; color: var(--text); overflow-wrap: anywhere; }
.short { border-left: 2px solid var(--accent); background: rgba(255, 255, 255, .025); padding: 16px 20px; border-radius: 0 10px 10px 0; margin: 0 0 1.6em; }
.short p:last-child, .short ul:last-child { margin-bottom: 0; }
.short-h { font: 500 11.5px/1 "JetBrains Mono", ui-monospace, monospace; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); margin-bottom: 10px !important; }
.note { border: 1px solid var(--line-2); border-radius: 10px; padding: 14px 18px; font-size: 15.5px; color: var(--muted); margin: 0 0 1.3em; }
.note p:last-child { margin: 0; }

.tbl { overflow-x: auto; margin: 0 0 1.4em; border: 1px solid var(--line); border-radius: 10px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 15px; line-height: 1.5; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); }
.prose th { color: var(--text); font-weight: 600; background: rgba(255, 255, 255, .03); white-space: nowrap; }
.prose tr:last-child td { border-bottom: 0; }

.fig { margin: 8px 0 1.6em; }
.fig svg { display: block; width: 100%; height: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.fig figcaption { font-size: 13.5px; color: var(--faint); margin-top: 10px; line-height: 1.5; }
.dg-box { fill: #1b1b1e; stroke: rgba(255, 255, 255, .16); }
.dg-hot { fill: rgba(201, 154, 94, .14); stroke: rgba(201, 154, 94, .7); }
.dg-t { fill: var(--text); font: 600 13px Inter, system-ui, sans-serif; }
.dg-s { fill: var(--muted); font: 400 11.5px Inter, system-ui, sans-serif; }
.dg-a { stroke: rgba(255, 255, 255, .35); stroke-width: 1.3; fill: none; }
.dg-k { fill: var(--accent); font: 500 10.5px "JetBrains Mono", ui-monospace, monospace; letter-spacing: .06em; }

.faq h3 { font-size: 18px; }
.beta-box { margin: 2.4em 0; padding: 26px 28px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface); font-size: 16px; }
.beta-box .kicker { margin-bottom: 12px; }
.beta-box p { color: var(--soft); }
.beta-links { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; margin: 4px 0 0 !important; }
.wrap > .beta-box { max-width: 820px; margin: 24px 0 96px; }
.sources h2 { font-size: 20px; }
.sources ol { font-size: 14.5px; line-height: 1.55; }
.sources a { overflow-wrap: anywhere; }
.src-note { font-size: 13.5px; color: var(--faint); }
.related { padding-bottom: 96px; }
.related > h2 { font-size: 24px; margin-bottom: 20px; }

@media (max-width: 1020px) {
  .post-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .toc { position: static; margin-bottom: 36px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 10px; }
  .toc ol { border: 0; }
  .toc li a { padding-left: 0; }
}
@media (max-width: 680px) {
  .post-head { padding-top: 24px; padding-bottom: 28px; }
  .post-grid { padding-top: 32px; }
  .prose { font-size: 17px; line-height: 1.7; }
  .post-dek { font-size: 17.5px; }
  .beta-box { padding: 22px 20px; }
  .ins-hero .kicker { margin-top: 36px; }
  .crumbs li[aria-current] { max-width: 24ch; }
  .fig-scroll { overflow-x: auto; border-radius: 12px; }
  .fig svg { min-width: 600px; }   /* diagram text stays readable; the figure scrolls sideways inside its own box */
}
