/* GDS blog single-post template. Same tokens as the landing page; maps to a WordPress single.html block template. */
:root {
  --bg: #FFFFFF; --surface: #F3F6FB; --card: #FFFFFF;
  --fg: #172033; --muted: #4F5B73; --line: #DAE2EE;
  --blue: #044FA0; --blue-bright: #1863DC; --blue-soft: #E6EEFB; --on-blue: #FFFFFF;
  --facet-1: #3CBEF0; --facet-2: #0099DF; --facet-3: #0070BA; --facet-4: #044FA0;
  --wait: #8A5300; --wait-soft: #FBF0DC;
  --shadow: 0 1px 2px rgba(10,42,87,.06), 0 12px 32px -12px rgba(10,42,87,.18);
  --display: "Poppins", "Segoe UI", Arial, sans-serif;
  --body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --wrap: 1200px; color-scheme: light;
}
html { scroll-behavior: smooth; scroll-padding-top: calc(env(safe-area-inset-top, 0px) + 90px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
[hidden] { display: none !important; }
p { margin: 0; }
a { color: var(--blue); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--blue-bright); outline-offset: 3px; border-radius: 6px; }
.ph { font-family: var(--mono); font-weight: 500; color: var(--wait); background: var(--wait-soft); border-radius: 6px; padding: 0 .25em; }
.eyebrow { font: 500 13px/1.3 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--blue); }
/* reading progress */
.progress { position: fixed; top: env(safe-area-inset-top, 0px); left: 0; right: 0; height: 3px; z-index: 70; background: transparent; }
.progress i { display: block; height: 100%; width: 100%; transform-origin: left; transform: scaleX(0); background: linear-gradient(90deg, var(--facet-1), var(--facet-2), var(--facet-4)); }
@media (max-width: 460px) { .head-cta { display: none; } }
/* article head */
.post-head { padding-block: clamp(36px, 6vw, 72px) 0; background: linear-gradient(180deg, var(--surface), var(--bg) 85%); }
.post-head .inner { max-width: 820px; display: grid; gap: 18px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; font: 500 13px/1.3 var(--mono); color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--blue); }
.cat { display: inline-flex; align-items: center; gap: 8px; justify-self: start; font: 500 12.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--blue); background: var(--blue-soft); padding: 7px 11px; border-radius: 999px; }
.post-head h1 { font-weight: 700; font-size: clamp(32px, 4.6vw, 52px); line-height: 1.1; letter-spacing: -0.02em; }
.dek { font-size: clamp(18px, 1.7vw, 21px); color: var(--muted); max-width: 62ch; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; padding-top: 6px; }
.byline { display: flex; align-items: center; gap: 12px; }
.avatar { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg, var(--facet-1), var(--facet-4)); flex: none; }
.byline b { display: block; font: 600 15px/1.3 var(--display); }
.byline small { display: block; font-size: 13.5px; color: var(--muted); }
.facts { display: flex; flex-wrap: wrap; gap: 6px 14px; font: 400 13.5px/1.3 var(--mono); color: var(--muted); }
.share { margin-left: auto; display: flex; gap: 8px; }
.share button, .share a { display: inline-flex; align-items: center; gap: 6px; font: 500 13.5px/1 var(--body); color: var(--fg); background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 8px 13px; min-height: 36px; cursor: pointer; text-decoration: none; }
.share svg { width: 15px; height: 15px; }
.share button:hover, .share a:hover { border-color: var(--blue); color: var(--blue); }
@media (max-width: 640px) { .share { margin-left: 0; } }
.cover { margin-top: clamp(28px, 4vw, 44px); border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: #0A2A57; aspect-ratio: 21 / 8; max-width: 100%; position: relative; }
.cover svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.cover figcaption { position: absolute; left: 18px; bottom: 14px; font: 400 12.5px/1.3 var(--mono); color: #AFC3E4; }
@media (max-width: 640px) { .cover { aspect-ratio: 4 / 3; } }
/* body + toc */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: clamp(32px, 5vw, 72px); padding-block: clamp(36px, 5vw, 56px) clamp(56px, 7vw, 88px); align-items: start; }
.toc { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 92px); order: 2; display: grid; gap: 18px; }
.toc nav { border-left: 2px solid var(--line); display: grid; }
.toc .eyebrow { margin-bottom: 4px; }
.toc nav a { display: block; padding: 7px 0 7px 14px; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; font-size: 14.5px; line-height: 1.35; transition: color .2s, border-color .2s; }
.toc nav a:hover { color: var(--fg); }
.toc nav a.on { color: var(--blue); border-left-color: var(--blue); font-weight: 600; }
.toc-cta { border: 1px solid var(--line); border-radius: 14px; padding: 18px; display: grid; gap: 10px; background: var(--surface); }
.toc-cta b { font: 600 16px/1.3 var(--display); }
.toc-cta p { font-size: 14.5px; color: var(--muted); }
.toc-m { display: none; }
@media (max-width: 960px) { .layout { grid-template-columns: minmax(0, 1fr); } .toc { display: none; } .toc-m { display: block; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 28px; background: var(--surface); } .toc-m summary { cursor: pointer; padding: 14px 16px; font: 600 15px/1.3 var(--display); list-style: none; display: flex; justify-content: space-between; } .toc-m summary::-webkit-details-marker { display: none; } .toc-m summary::after { content: "+"; color: var(--blue); } .toc-m[open] summary::after { content: "–"; } .toc-m nav { display: grid; padding: 0 16px 12px; } .toc-m a { padding: 7px 0; color: var(--fg); text-decoration: none; font-size: 15px; border-top: 1px solid var(--line); } }
.prose { min-width: 0; max-width: 700px; }
.prose > * + * { margin-top: 20px; }
.prose h2 { font-weight: 600; font-size: clamp(24px, 2.6vw, 30px); line-height: 1.2; letter-spacing: -0.01em; margin-top: 48px; }
.prose h3 { font-weight: 600; font-size: 19px; margin-top: 30px; }
.prose p, .prose li { color: #26314A; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 8px; }
.prose .lede { font-size: 19.5px; line-height: 1.6; color: var(--fg); }
.prose .lede::first-letter { float: left; font: 700 62px/.9 var(--display); color: var(--blue); padding: 6px 8px 0 0; }
.takeaways { border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; background: var(--surface); }
.takeaways .eyebrow { margin-bottom: 10px; }
.takeaways ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.takeaways li { position: relative; padding-left: 20px; margin: 0; }
.takeaways li::before { content: ""; position: absolute; left: 0; top: .6em; width: 8px; height: 8px; background: var(--facet-1); transform: skewX(-20deg); }
.stat { border: 1px solid var(--line); border-radius: 14px; padding: 22px; display: grid; gap: 14px; }
.stat .row { display: grid; grid-template-columns: 190px minmax(0, 1fr) 52px; gap: 12px; align-items: center; font: 400 14px/1.3 var(--mono); color: var(--muted); }
.stat .row i { display: block; height: 14px; border-radius: 8px; background: var(--facet-2); transform-origin: left; transform: scaleX(0); transition: transform 1.1s cubic-bezier(.2,.7,.2,1); }
.stat .row.dim i { background: #C3CEDF; }
.stat.in .row i { transform: none; }
.stat .row em { font-style: normal; font: 600 18px/1 var(--display); color: var(--fg); text-align: right; }
.stat figcaption { font-size: 13.5px; color: var(--muted); }
@media (max-width: 520px) { .stat .row { grid-template-columns: 1fr 52px; } .stat .row i { grid-column: 1 / -1; grid-row: 2; } }
blockquote.pull { margin: 36px 0; padding: 4px 0 4px 22px; border-left: 4px solid var(--facet-2); font: 500 clamp(20px, 2.2vw, 24px)/1.45 var(--display); color: var(--fg); }
.steps { list-style: none; padding: 0 !important; counter-reset: st; display: grid; gap: 12px; }
.steps li { counter-increment: st; position: relative; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px 16px 62px; margin: 0 !important; }
.steps li::before { content: "0" counter(st); position: absolute; left: 18px; top: 16px; font: 500 14px/1.6 var(--mono); color: var(--blue); }
.steps b { font-family: var(--display); font-weight: 600; }
.inline-cta { border-radius: 16px; padding: 24px; background: var(--blue); color: var(--on-blue); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; margin-block: 40px !important; }
.inline-cta b { display: block; font: 600 20px/1.3 var(--display); }
.inline-cta span { color: #CFE0F7; font-size: 15.5px; }
.inline-cta .btn { background: var(--card); color: var(--blue); }
.inline-cta .btn:hover { background: var(--blue-soft); }
.sources { border-top: 1px solid var(--line); padding-top: 20px; margin-top: 44px !important; font-size: 14.5px; color: var(--muted); }
.sources ol { margin: 8px 0 0; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags a { font: 500 13px/1 var(--mono); color: var(--muted); text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 8px 12px; }
.tags a:hover { color: var(--blue); border-color: var(--blue); }
.author { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px; border: 1px solid var(--line); border-radius: 16px; padding: 22px; margin-top: 36px !important; }
.author .avatar { width: 64px; height: 64px; }
.author b { font: 600 17px/1.3 var(--display); }
.author p { font-size: 15px; color: var(--muted); margin-top: 4px; }
/* related + cta */
.related { background: var(--surface); padding-block: clamp(48px, 6vw, 80px); border-top: 1px solid var(--line); }
.related h2 { font-weight: 600; font-size: clamp(26px, 3vw, 34px); margin-bottom: 28px; }
.rel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.rel a { display: grid; gap: 10px; align-content: start; border: 1px solid var(--line); border-radius: 14px; padding: 22px; background: var(--card); text-decoration: none; color: var(--fg); transition: translate .25s, box-shadow .25s, border-color .2s; }
.rel a:hover { translate: 0 -3px; box-shadow: var(--shadow); border-color: var(--facet-2); }
.rel .src { font: 500 12.5px/1.3 var(--mono); color: var(--blue); text-transform: uppercase; letter-spacing: .06em; }
.rel b { font: 600 18px/1.3 var(--display); }
.rel span:last-child { font-size: 14.5px; color: var(--muted); }
@media (max-width: 900px) { .rel { grid-template-columns: minmax(0, 1fr); } }
.end-cta { padding-block: clamp(56px, 7vw, 88px); }
.end-cta .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; }
.end-cta h2 { font-weight: 600; font-size: clamp(28px, 3.4vw, 40px); line-height: 1.15; max-width: 18ch; }
.end-cta p { color: var(--muted); max-width: 46ch; margin-top: 10px; }
:root .rv { opacity: 0; transform: translateY(16px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
:root .rv.in { opacity: 1; transform: none; }
