.article-main { padding-bottom: 0; }
.article-header { position: relative; padding: 110px 0 56px; }
.back-link { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 44px; font-size: 14px; color: var(--text-2); transition: color 0.3s; }
.back-link:hover { color: var(--text); }
.page-kicker { margin: 0 0 24px; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); }
.article-header h1 { margin: 0; max-width: 20ch; font-family: var(--serif); font-weight: 500; font-size: clamp(38px, 5vw, 66px); letter-spacing: -0.02em; line-height: 1.05; text-wrap: balance; }
.article-deck { max-width: 56ch; margin: 28px 0 0; font-size: clamp(17px, 1.4vw, 20px); line-height: 1.55; color: var(--text-2); text-wrap: pretty; }
.article-byline { margin: 28px 0 0; font-family: var(--mono); font-size: 13px; color: var(--muted); }

.article-layout { display: grid; grid-template-columns: 230px minmax(0, 720px); gap: 90px; justify-content: center; padding: 50px 0 120px; border-top: 1px solid var(--line); }
.article-aside, .article-body { min-width: 0; max-width: 100%; }
.article-aside { position: sticky; top: 100px; align-self: start; padding-top: 50px; }
.article-aside > p { margin: 0 0 18px; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); }
.article-aside ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.article-aside li { counter-increment: toc; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; line-height: 1.45; }
.article-aside li::before { content: "0" counter(toc); display: block; margin-bottom: 2px; font-size: 10.5px; letter-spacing: 0.12em; color: var(--muted); }
.article-aside a { color: var(--text-2); transition: color 0.3s; }
.article-aside a:hover { color: var(--text); }

.article-body { padding-top: 50px; font-size: 18px; line-height: 1.75; }
.article-body p { margin: 0 0 26px; text-wrap: pretty; }
.article-body .lead { margin-bottom: 36px; font-family: var(--serif); font-size: 25px; line-height: 1.4; letter-spacing: -0.01em; color: var(--text); }
.article-body h2 { margin: 66px 0 20px; font-family: var(--serif); font-weight: 500; font-size: 33px; letter-spacing: -0.015em; line-height: 1.15; }
.article-body h3 { margin: 40px 0 14px; font-family: var(--serif); font-weight: 500; font-size: 23px; line-height: 1.25; }
.article-body a { color: var(--blue); border-bottom: 1px solid rgba(54, 93, 137, 0.35); overflow-wrap: anywhere; transition: border-color 0.3s; }
.article-body a:hover { border-color: var(--blue); }
.article-body em { font-style: normal; font-weight: 600; color: var(--text); }
.article-body code { font-family: var(--mono); font-size: 0.86em; padding: 1px 6px; border-radius: 5px; background: var(--bg-2); border: 1px solid var(--line); }
.article-body pre { max-width: 100%; overflow-x: auto; }
.article-close { margin-top: 56px !important; padding-top: 28px; border-top: 1px solid var(--line-2); font-family: var(--serif); font-size: 24px; line-height: 1.4; }

.figure { position: relative; }
.article-figure { margin: 44px 0; }
.panel { position: relative; padding: 26px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--bg); }
.panel--dark { background: var(--gold-wash); border-color: #e6dcc6; }
.panel .kicker { margin: 0 0 18px; }
.figure-caption { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 16px 4px 0; font-family: var(--mono); font-size: 12.5px; line-height: 1.55; color: var(--muted); }
.figure-caption b { font-weight: 500; color: var(--text); }

.evidence-comparison__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.evidence-comparison__grid .panel { padding: 22px; }
.evidence-comparison__grid h3 { margin: 8px 0 10px; font-family: var(--serif); font-weight: 500; font-size: 21px; line-height: 1.25; }
.evidence-comparison__grid p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-2); }
.evidence-comparison__grid .kicker { margin-bottom: 12px; }

.perf-source { margin: -12px 0 26px; font-family: var(--mono); font-size: 12.5px; line-height: 1.6; color: var(--muted); }
.article-body .perf-source a { color: var(--text-2); border-bottom-color: var(--line-2); }
.perf-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 18px; font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
.perf-legend i { display: inline-block; width: 14px; height: 8px; margin-right: 6px; border-radius: 2px; vertical-align: 1px; background: var(--line-2); }
.perf-legend i.is-after { background: var(--gold); }
.perf-bars { display: grid; gap: 14px; }
.perf-row { display: grid; grid-template-columns: 170px minmax(0, 1fr) 96px; gap: 14px; align-items: center; }
.perf-row__k { font-size: 13.5px; line-height: 1.35; color: var(--text); }
.perf-row__k small { display: block; font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
.perf-track { display: grid; gap: 3px; }
.perf-bar { height: 10px; border-radius: 0 4px 4px 0; background: var(--line-2); }
.perf-bar--after { background: var(--gold); }
.perf-delta { text-align: right; font-family: var(--mono); font-size: 13px; font-weight: 500; color: var(--gold); }
.perf-delta.is-flat { color: var(--muted); }
.perf-tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.perf-tile { min-width: 0; padding: 16px 14px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-2); }
.perf-tile b { display: block; font-family: var(--serif); font-weight: 500; font-size: 27px; letter-spacing: -0.02em; line-height: 1.1; }
.perf-tile span { display: block; margin-top: 8px; font-size: 13px; line-height: 1.45; color: var(--text); }
.perf-tile small { display: block; margin-top: 10px; font-family: var(--mono); font-size: 11px; line-height: 1.4; color: var(--muted); }

.perf-rail { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.flow-step { display: flex; flex-direction: column; gap: 8px; min-width: 0; padding: 16px 14px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-2); }
.flow-step--highlight { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); background: var(--bg); }
.flow-step__k { margin: 0; font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.02em; color: var(--muted); }
.flow-step__k b { display: block; margin-bottom: 2px; font-weight: 500; color: var(--gold); }
.flow-step strong { display: block; font-family: var(--serif); font-weight: 500; font-size: 17px; line-height: 1.3; }
.flow-step p { margin: 0; font-size: 12.5px; line-height: 1.5; color: var(--text-2); overflow-wrap: break-word; }
.flow-return { display: grid; grid-template-columns: 1fr; margin-top: 14px; color: var(--muted); }
.flow-return svg { width: 100%; height: 44px; }
.flow-return p { margin: -6px 0 0; text-align: center; font-family: var(--mono); font-size: 12.5px; }

.gate { display: grid; grid-template-columns: minmax(0, 1fr) 150px minmax(0, 1.1fr); gap: 22px; align-items: center; }
.gate-column { display: grid; gap: 10px; align-content: start; }
.gate-column > .kicker { margin-bottom: 4px; }
.gate-item { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg); font-size: 14px; }
.gate-item strong { display: block; font-size: 14.5px; letter-spacing: -0.01em; }
.gate-item small { display: block; font-size: 12.5px; line-height: 1.45; color: var(--text-2); }
.gate-item code { font-family: var(--mono); font-size: 12.5px; color: var(--muted); }
.gate-item--ok { border-color: rgba(147, 115, 52, 0.55); }
.gate-pip { width: 10px; height: 10px; margin-top: 5px; border-radius: 50%; background: var(--line-2); }
.gate-item--ok .gate-pip { background: var(--gold); }
.gate-item--reject .gate-pip { background: var(--muted); }
.gate-core { position: relative; display: grid; gap: 8px; padding: 22px 16px; border: 1px solid var(--ink); border-radius: 12px; background: var(--bg); text-align: center; }
.gate-core::before, .gate-core::after { content: ""; position: absolute; top: 50%; width: 22px; height: 1px; background: var(--line-2); }
.gate-core::before { left: -22px; }
.gate-core::after { right: -22px; }
.gate-core .kicker { margin: 0; justify-self: center; }
.gate-core strong { font-family: var(--serif); font-weight: 500; font-size: 16px; line-height: 1.3; }
.gate-core ul { margin: 6px 0 0; padding: 0; list-style: none; font-family: var(--mono); font-size: 11.5px; line-height: 1.7; color: var(--text-2); }
.gate-core svg { width: 40px; height: 40px; margin: 6px auto 2px; color: var(--ink); }

.article-footer { display: flex; align-items: end; justify-content: space-between; gap: 60px; padding: 80px 0; border-top: 1px solid var(--line-2); }
.article-footer h2 { max-width: 18ch; margin: 0; font-family: var(--serif); font-weight: 500; font-size: clamp(30px, 3.6vw, 46px); letter-spacing: -0.015em; line-height: 1.1; text-wrap: balance; }
.article-footer .page-kicker { margin-bottom: 18px; }
.perf-cta { display: flex; flex-wrap: wrap; gap: 12px; }

@media (max-width: 1000px) {
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .article-aside { position: static; padding-bottom: 8px; }
  .article-aside ol { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; }
  .article-body { padding-top: 24px; }
}
@media (max-width: 800px) {
  .article-header { padding: 80px 0 44px; }
  .article-aside ol { grid-template-columns: minmax(0, 1fr); }
  .article-body { font-size: 17px; }
  .article-body .lead { font-size: 22px; }
  .article-body h2 { font-size: 28px; margin-top: 52px; }
  .panel { padding: 18px; }
  .evidence-comparison__grid { grid-template-columns: minmax(0, 1fr); }
  .perf-row { grid-template-columns: 1fr; gap: 6px; }
  .perf-delta { text-align: left; }
  .perf-tiles, .perf-rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .flow-return svg { display: none; }
  .flow-return p { margin-top: 12px; text-align: left; }
  .gate { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .gate-core { margin: 10px 0; }
  .gate-core::before, .gate-core::after { top: auto; left: 50%; width: 1px; height: 18px; transform: translateX(-50%); }
  .gate-core::before { top: -18px; }
  .gate-core::after { right: auto; bottom: -18px; }
  .article-footer { flex-direction: column; align-items: start; gap: 28px; padding: 60px 0; }
}
.article-figure.evidence-comparison { margin-bottom: 52px; }
