/* Blog: index, post page and the latest posts on the home page. Tokens come from site.css. */

/* Cards */
.post-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:64px 36px}
.post-card,.post-lead{position:relative;min-width:0}
.post-card{display:flex;flex-direction:column}
.post-cover{aspect-ratio:1200/630;border:1px solid var(--line);border-radius:20px;overflow:hidden;background:#edf2fa}
.post-cover img{width:100%;height:100%;object-fit:cover;transition:transform .9s var(--ease)}
.post-cover.is-empty{display:grid;place-items:center;background:linear-gradient(140deg,#e6edfc,#eff4fe 65%,#dfebfc)}
.post-cover.is-empty img{width:46px;height:auto;object-fit:contain}
.post-card-copy{display:flex;flex-direction:column;flex:1;padding-top:22px}
.post-meta{display:flex;flex-wrap:wrap;row-gap:2px;overflow:hidden;color:var(--muted);font-size:13px;line-height:1.5}
/* Each item carries its dot in a left gutter. The gutter of the first item on a line is clipped, so a wrapped line never starts with a dot. */
.post-meta>*{position:relative;margin:0 22px 0 -22px;padding-left:22px}
.post-meta>*::before{content:"";position:absolute;left:9px;top:50%;width:3px;height:3px;margin-top:-1px;border-radius:50%;background:#9aa8b8}
.post-category{color:var(--blue);font-weight:500}
.post-card-title{margin-top:12px;font-size:22px;font-weight:500;line-height:1.24;letter-spacing:-.03em;text-wrap:balance}
.post-card-title a{transition:color .3s}
.post-card-title a::after{content:"";position:absolute;inset:0;border-radius:20px}
.post-card-title a:focus-visible{outline:none}
.post-card-title a:focus-visible::after{outline:3px solid #6592ff;outline-offset:8px}
.post-card-excerpt{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;margin-top:10px;color:var(--muted);font-size:15px;line-height:1.65}
.post-card-foot{margin-top:auto;padding-top:16px;color:var(--muted);font-size:13px}
@media(hover:hover){
  .post-card:hover .post-card-title a,.post-lead:hover .post-card-title a{color:var(--blue)}
  .post-card:hover .post-cover:not(.is-empty) img,.post-lead:hover .post-cover:not(.is-empty) img{transform:scale(1.025)}
}

/* The newest post */
.post-lead{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:64px;align-items:center}
.post-lead .post-cover{border-radius:24px}
.post-lead .post-card-copy{padding-top:0}
.post-lead .post-card-title{margin-top:16px;font-size:clamp(30px,3.1vw,44px);line-height:1.1;letter-spacing:-.045em}
.post-lead .post-card-title a::after{border-radius:24px}
.post-lead .post-card-excerpt{-webkit-line-clamp:4;margin-top:18px;font-size:17px}
.post-lead .post-card-foot{margin-top:0;padding-top:22px}
.post-lead+.post-grid{margin-top:72px;padding-top:72px;border-top:1px solid var(--line)}

/* Index */
.inner-hero.blog-hero{padding-bottom:64px}
.blog-hero-links{margin-top:18px}
.blog-hero-links .text-link,.blog-empty .text-link{min-height:44px}
.blog-list{padding-bottom:112px}
.blog-pagination{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:20px;margin-top:80px}
.blog-pagination p{color:var(--muted);font-size:14px}
.blog-pagination>:first-child{justify-self:start}
.blog-pagination>:last-child{justify-self:end}
.blog-feed{margin-top:56px;padding-top:20px;border-top:1px solid var(--line);color:var(--muted);font-size:13px}
.blog-feed a{display:inline-flex;align-items:center;min-height:44px;text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:4px}
.blog-feed a:hover{color:var(--blue)}
.blog-empty{max-width:640px;padding:48px;border:1px solid var(--line);border-radius:var(--radius);background:#fff}
.blog-empty h2{font-size:28px;line-height:1.2;letter-spacing:-.035em}
.blog-empty p{margin-top:12px;color:var(--muted);font-size:16px;line-height:1.65}
.blog-empty .text-link{margin-top:12px}
.blog-preview-note{padding:12px 20px;background:#edf3ff;color:var(--ink);font-size:14px;line-height:1.5;text-align:center}
.blog-preview-note strong{margin-right:8px;font-weight:600}

/* Latest posts: home page and the foot of a post */
.blog-latest{background:#fff}
.blog-latest-head{display:flex;align-items:flex-end;justify-content:space-between;gap:32px;margin-bottom:56px}
.blog-latest-head .text-link{flex-shrink:0;min-height:44px}
.post-more{padding:96px 0 112px;border-top:1px solid var(--line);background:var(--paper)}
.post-more .section-heading{font-size:clamp(30px,3vw,42px)}

/* Post page */
body.blog-page[data-page=blog-post]{background:#fff}
.post{padding:20px 0 104px}
/* One column. The title, the cover, charts, tables and key numbers all share the edges of the text, and nothing
   reaches past them. The authors sit beside the column on a wide screen and under the title on a narrow one. */
.post-layout{display:grid;grid-template-columns:minmax(0,720px) 232px;column-gap:88px;justify-content:center;align-items:start}
.post-header,.post-column{grid-column:1;min-width:0}
.post-rail{grid-column:2;grid-row:2;position:sticky;top:120px;padding-top:52px}
.post-rail h2{color:var(--muted);font-size:12px;font-weight:600;line-height:1.5;letter-spacing:.14em;text-transform:uppercase}
.post-authors ul{display:grid;gap:18px;margin-top:18px}
.post-author{display:flex;align-items:center;gap:13px;min-width:0}
.post-author-photo{flex:none;width:44px;height:44px;border-radius:50%;object-fit:cover;background:#edf2fa}
.post-author-photo.is-initials{display:grid;place-items:center;background:#e6edfc;color:var(--blue);font-size:14px;font-weight:600;letter-spacing:.03em}
.post-author-text{display:flex;flex-direction:column;min-width:0}
.post-author-name{color:var(--ink);font-size:16px;font-weight:500;line-height:1.35;letter-spacing:-.015em}
.post-author-name a:hover{color:var(--blue)}
.post-author-role{margin-top:2px;color:var(--muted);font-size:13px;line-height:1.45}
.post-breadcrumb ol{display:flex;align-items:center;min-width:0;margin:0;padding:0;list-style:none;color:var(--muted);font-size:13px;line-height:1.5}
.post-breadcrumb li{display:flex;align-items:center;flex-shrink:0;min-height:44px}
.post-breadcrumb li+li::before{content:"/";margin:0 10px;color:#9aa8b8}
.post-breadcrumb li:last-child{display:block;flex:0 1 auto;min-width:0;min-height:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.post-breadcrumb a{display:inline-flex;align-items:center;min-height:44px}
.post-breadcrumb a:hover{color:var(--blue)}
.post-header .post-meta{margin-top:36px;font-size:14px}
.post-header h1{margin-top:18px;font-size:clamp(34px,3.7vw,50px);font-weight:500;line-height:1.08;letter-spacing:-.048em;text-wrap:balance}
.post-standfirst{margin-top:26px;color:var(--muted);font-size:clamp(18px,1.55vw,21px);line-height:1.6}
/* A figure keeps the browser's side margins unless told otherwise, and those would set it in from the text. */
.post-layout figure{margin-inline:0}
.post-figure{margin-block:48px}
.post-figure img{width:100%;height:auto;border:1px solid var(--line);border-radius:20px;background:#fff}
.post-figure figcaption{margin-top:14px;color:var(--muted);font-size:14px;line-height:1.6}
.post-column>.post-cover-figure{margin-block:52px 0}
.post-cover-figure img{border-radius:var(--radius)}

.post-takeaways{margin-top:52px;padding:32px 36px 34px;border:1px solid var(--line);border-radius:var(--radius);background:var(--paper)}
.post-takeaways h2{color:var(--blue);font-size:13px;font-weight:600;line-height:1.5;letter-spacing:.13em;text-transform:uppercase}
.post-takeaways ul{margin-top:18px}
.post-takeaways li{position:relative;padding-left:24px;color:var(--ink);font-size:17px;line-height:1.6}
.post-takeaways li+li{margin-top:12px}
.post-takeaways li::before,ul.post-list>li::before{content:"";position:absolute;left:2px;top:.72em;width:6px;height:6px;border-radius:50%;background:var(--blue)}

.post-body{margin-top:52px;color:#2c435a;font-size:18px;line-height:1.72}
.post-body>:first-child{margin-top:0}
.post-body>p{margin-top:1.3em}
.post-body>h2,.post-faq>h2,.post-sources>h2{color:var(--ink);font-size:clamp(26px,2.5vw,33px);font-weight:500;line-height:1.18;letter-spacing:-.04em;text-wrap:balance;scroll-margin-top:120px}
.post-body>h2{margin-top:2.1em}
.post-body>h3{margin-top:1.8em;color:var(--ink);font-size:22px;font-weight:500;line-height:1.3;letter-spacing:-.025em}
.post-body>h2+p,.post-body>h3+p,.post-body>h2+.post-list,.post-body>h3+.post-list{margin-top:.8em}
.post-column :is(.post-body,.post-takeaways,.post-faq,.post-sources) a{color:var(--blue);text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:3px}
.post-column :is(.post-body,.post-takeaways,.post-faq,.post-sources) a:hover{color:var(--blue-dark)}
.post-body strong,.post-takeaways strong{color:var(--ink);font-weight:600}
/* Footnotes: a number next to the fact that opens its source. On a screen with a pointer the source's name shows
   on hover. The card hangs from the number to the right, and only where the layout leaves room beside the column. */
.post-cite{position:relative;margin-left:1px;font-size:.62em;line-height:0;vertical-align:.62em;font-variant-numeric:tabular-nums}
.post-column .post-cite a{padding:2px 1px;color:var(--blue);font-weight:500;text-decoration:none;white-space:nowrap}
.post-column .post-cite a:hover{color:var(--blue-dark);text-decoration:underline;text-underline-offset:2px}
.post-cite-card{display:none}
@media(hover:hover) and (min-width:1141px){
  .post-cite-card{position:absolute;left:-6px;top:calc(100% + 14px);z-index:5;display:flex;flex-direction:column;gap:3px;width:max-content;max-width:300px;padding:11px 14px 12px;border:1px solid var(--line);border-radius:12px;background:#fff;box-shadow:0 12px 32px #10243a14;color:var(--ink);font-size:13px;font-weight:400;line-height:1.45;letter-spacing:0;text-align:left;white-space:normal;opacity:0;visibility:hidden;transition:opacity .15s,visibility .15s;pointer-events:none}
  .post-cite:hover .post-cite-card,.post-cite:focus-within .post-cite-card{opacity:1;visibility:visible}
  .post-cite-host{color:var(--muted);font-size:12px}
}
.post-column code{padding:.14em .4em;border-radius:6px;background:#edf2fa;color:var(--ink);font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:.86em}
.post-list{margin:1.1em 0 0;padding:0;list-style:none}
.post-list>li{position:relative;padding-left:26px}
.post-list>li+li{margin-top:.55em}
ol.post-list{counter-reset:post-item}
ol.post-list>li{padding-left:34px;counter-increment:post-item}
ol.post-list>li::before{content:counter(post-item);position:absolute;left:0;top:0;color:var(--blue);font-size:.84em;font-weight:500;line-height:2.05}

.post-quote{margin-block:44px;padding-left:28px;border-left:2px solid var(--blue)}
.post-quote blockquote{margin:0}
.post-quote p{color:var(--ink);font-size:clamp(21px,2vw,26px);line-height:1.42;letter-spacing:-.025em}
.post-quote figcaption{margin-top:14px;color:var(--muted);font-size:14px}

.post-callout{margin-block:40px;padding:26px 30px 28px;border-radius:20px;background:#edf3ff}
.post-callout-title{margin-bottom:6px;color:var(--ink);font-size:16px;font-weight:600;line-height:1.5}
.post-callout p:not(.post-callout-title){color:#2c435a;font-size:16px;line-height:1.7}

/* Key numbers: one band as wide as the text. Rows are shared, so values line up when a label wraps. */
.post-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));margin-block:44px;border:1px solid var(--line);border-radius:20px;background:var(--paper);overflow:hidden}
.post-stats[data-count="1"]{grid-template-columns:minmax(0,1fr)}
.post-stats[data-count="2"]{grid-template-columns:repeat(2,minmax(0,1fr))}
.post-stats[data-count="3"]{grid-template-columns:repeat(3,minmax(0,1fr))}
/* Every tile draws its top and left rule and steps over the frame by a pixel, so only the rules between tiles show, however they wrap. */
.post-stat{display:grid;grid-template-rows:subgrid;grid-row:span 3;align-content:start;min-width:0;margin:-1px 0 0 -1px;padding:20px 20px 22px;border:solid var(--line);border-width:1px 0 0 1px}
.post-stat dt{color:var(--muted);font-size:13px;line-height:1.45}
.post-stat dd{margin:0}
.post-stat-value{padding-top:10px;color:var(--ink);font-size:26px;font-weight:500;line-height:1.1;letter-spacing:-.04em;overflow-wrap:anywhere}
.post-stat-delta{padding-top:8px;color:var(--muted);font-size:13px;line-height:1.45}
.post-stat-delta.is-up{color:#00823a}
.post-stat-delta.is-down{color:#c2222b}
.post-stat-delta.is-up::before,.post-stat-delta.is-down::before{content:"";display:inline-block;margin-right:6px;border:4px solid transparent;border-bottom:6px solid currentColor;border-top:0;vertical-align:.08em}
.post-stat-delta.is-down::before{border-top:6px solid currentColor;border-bottom:0}

.post-table{margin-block:44px}
.post-table>figcaption{margin-bottom:12px;color:var(--ink);font-size:15px;font-weight:500;line-height:1.5}
/* The table scrolls inside its frame. Edge shadows show that more columns are off screen. */
.post-table-scroll{overflow-x:auto;border:1px solid var(--line);border-radius:16px;-webkit-overflow-scrolling:touch;background:linear-gradient(90deg,#fff 40%,#fff0) 0 0/36px 100% no-repeat local,linear-gradient(270deg,#fff 40%,#fff0) 100% 0/36px 100% no-repeat local,linear-gradient(90deg,#10243a24,#10243a00) 0 0/14px 100% no-repeat scroll,linear-gradient(270deg,#10243a24,#10243a00) 100% 0/14px 100% no-repeat scroll,#fff}
.post-table-scroll:focus-visible{outline-offset:3px}
.post-table table{width:100%;border-collapse:collapse;font-size:15px;line-height:1.5;font-variant-numeric:tabular-nums}
.post-table th{padding:13px 20px;border-bottom:1px solid var(--line);background:#10243a06;color:var(--muted);font-size:13px;font-weight:500;text-align:left;white-space:nowrap}
.post-table td{padding:14px 20px;border-bottom:1px solid #edf1f6;color:#2c435a;vertical-align:top}
.post-table td:first-child{color:var(--ink);font-weight:500}
.post-table tbody tr:last-child td{border-bottom:0}
.post-table .num{text-align:right;white-space:nowrap}
.post-table-note{margin-top:10px;color:var(--muted);font-size:13px;line-height:1.55}

.post-faq,.post-sources{margin-top:64px}
.post-faq .faq-list{margin-top:22px}
.post-faq .faq-list summary{font-size:17px}
.post-faq .faq-list details p{color:#2c435a;font-size:16px;line-height:1.7}
.post-sources>h2{font-size:22px;letter-spacing:-.025em}
/* Room for a two-digit number inside the column. */
.post-sources ol{margin:8px 0 0;padding-left:30px;color:var(--muted);font-size:15px;line-height:1.6}
/* The link stays inline, so the number sits on the first line of a title that wraps. */
.post-sources li{padding:10px 0 10px 4px}
.post-sources span{color:var(--muted);font-size:13px;margin-left:6px}
.post-tags{display:flex;flex-wrap:wrap;gap:8px;margin-top:44px}
.post-tags a{display:inline-flex;align-items:center;min-height:44px;padding:10px 18px;border:1px solid var(--line);border-radius:100px;color:var(--ink);font-size:13px;transition:border-color .3s,color .3s}
.post-tags a:hover{border-color:#b8c8db;color:var(--blue)}
.post-disclaimer{margin-top:40px;padding-top:24px;border-top:1px solid var(--line);color:var(--muted);font-size:13px;line-height:1.6}

@media(max-width:1000px){
  .post-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:52px 28px}
  .post-lead{grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:40px}
  .blog-latest .post-card:nth-child(3),.post-more .post-card:nth-child(3){display:none}
}
@media(max-width:1140px){
  .post-layout{grid-template-columns:minmax(0,720px)}
  .post-rail{grid-column:1;grid-row:auto;position:static;padding-top:26px}
  .post-rail h2{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
  .post-authors ul{display:flex;flex-wrap:wrap;gap:14px 30px;margin-top:0}
}
@media(max-width:740px){
  .post-grid{grid-template-columns:minmax(0,1fr);gap:44px}
  .post-cover,.post-lead .post-cover{border-radius:16px}
  .post-lead{display:flex;flex-direction:column;align-items:stretch;gap:0}
  .post-lead .post-card-copy{padding-top:22px}
  .post-lead .post-card-title{margin-top:12px;font-size:30px;line-height:1.13}
  .post-lead .post-card-excerpt{margin-top:12px;font-size:16px}
  .post-lead .post-card-foot{padding-top:16px}
  .post-lead+.post-grid{margin-top:48px;padding-top:48px}
  .post-card-title{font-size:21px}
  .inner-hero.blog-hero{padding-bottom:44px}
  .inner-hero.blog-hero h1{font-size:clamp(34px,10.2vw,40px)}
  .blog-list{padding-bottom:76px}
  .blog-pagination{grid-template-columns:1fr 1fr;margin-top:56px}
  .blog-pagination p{grid-column:1/-1;grid-row:1;text-align:center}
  .blog-empty{padding:32px 26px}
  .blog-latest-head{flex-direction:column;align-items:flex-start;gap:14px;margin-bottom:36px}
  .blog-latest .post-card:nth-child(3),.post-more .post-card:nth-child(3){display:flex}
  .post-more{padding:64px 0 76px}
  .post{padding:6px 0 72px}
  .post-header .post-meta{margin-top:20px;font-size:13px}
  .post-header h1{margin-top:14px;font-size:clamp(31px,8.6vw,38px);line-height:1.1}
  .post-standfirst{margin-top:18px;font-size:17px}
  .post-column>.post-cover-figure{margin-top:32px}
  .post-figure{margin-block:34px}
  .post-figure img,.post-cover-figure img{border-radius:14px}
  .post-figure figcaption{margin-top:10px;font-size:13px}
  .post-takeaways{margin-top:34px;padding:24px 22px 26px;border-radius:20px}
  .post-takeaways li{font-size:16px}
  .post-body{margin-top:36px;font-size:17px;line-height:1.7}
  .post-body>h2{margin-top:1.9em}
  .post-body>h3{font-size:20px}
  .post-quote{margin-block:34px;padding-left:20px}
  .post-callout{margin-block:32px;padding:22px 22px 24px;border-radius:18px}
  .post-rail{padding-top:20px}
  .post-author-photo{width:38px;height:38px}
  .post-author-name{font-size:15px}
  .post-stats,.post-stats[data-count="3"]{grid-template-columns:repeat(2,minmax(0,1fr));margin-block:34px;border-radius:18px}
  .post-stat{padding:16px 16px 18px}
  .post-stat-value{font-size:24px}
  .post-table{margin-block:34px}
  .post-table table{font-size:14px}
  .post-table th,.post-table td{padding:12px 14px}
  .post-table td:first-child{min-width:136px}
  .post-faq,.post-sources{margin-top:48px}
  .post-faq .faq-list summary{font-size:16px}
  .post-tags{margin-top:34px}
}
@media(prefers-reduced-motion:reduce){.post-cover img{transition:none}.post-card:hover .post-cover img,.post-lead:hover .post-cover img{transform:none}}
