/* Standalone case-study pages and the /blog/ index (/blog/<slug>/, /blog/).
   The banner and section blocks are styled by case-study.css; this file is
   the page around them: tokens, nav, the
   overlapping paper card, "more case studies"/blog listing, footer and the
   scroll-in motion. The color/font tokens mirror index.html's inline
   <style> — keep them in step by hand if the site's palette changes. The nav
   itself is shared via render.js's navHtml(), so it can't drift. */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #18160f;
  --black: #100e09;
  --paper: #f4eee0;
  --ink: #1b1810;
  --orange: #ff6a3d;
  --orange-ink: #b8431c;
  --blue: #3b82f6;
  --sub: rgba(244,238,224,.62);
  --border-ink: rgba(27,24,16,0.16);
  --serif: 'Bricolage Grotesque', system-ui, sans-serif;
  --sans: 'Work Sans', system-ui, sans-serif;
  --hand: 'Caveat', cursive;
  --max: 900px;
  /* The entry's banner color, also used for the progress bar and accents.
     Overridden on <body> with an inline style by scripts/site-pages.js. */
  --modal-accent: var(--orange);
}

html { scroll-behavior: smooth; }
html, body { overflow-x: clip; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--paper);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* General blog posts use the same paper-and-ink language as case studies. */
.blog-post { max-width: 760px; margin: 70px auto; padding: 42px; background: var(--paper); color: var(--ink); border-radius: 4px; }
.blog-post h1 { font: 700 clamp(38px, 7vw, 64px)/1.05 var(--serif); margin: 10px 0 18px; }
.blog-post-kicker { color: var(--orange-ink); font-weight: 700; text-transform: uppercase; letter-spacing: .09em; font-size: 12px; }
.blog-post-excerpt { font-size: 20px; line-height: 1.5; color: rgba(27,24,16,.7); margin-bottom: 28px; }
.blog-post-cover { width: 100%; max-height: 480px; object-fit: cover; margin: 0 0 28px; }
.blog-post-body { font-size: 18px; line-height: 1.75; }
.blog-post-body h2 { font: 600 30px/1.2 var(--serif); margin: 36px 0 12px; }
.blog-post-body p, .blog-post-body ul, .blog-post-body ol, .blog-post-body blockquote { margin: 0 0 20px; }
.blog-post-body figure { margin: 28px 0; }
.blog-post-body figure img { display:block; width:100%; max-height:680px; object-fit:cover; }
.blog-post-body figcaption { margin-top:8px; color:rgba(27,24,16,.62); font-size:14px; }
.blog-post-body blockquote { border-left: 4px solid var(--orange); padding-left: 18px; font-style: italic; }
.blog-post-video { position:relative; padding-top:56.25%; margin:0 0 28px; }.blog-post-video iframe { position:absolute; inset:0; width:100%; height:100%; border:0; }
.blog-post--note .blog-post-body { max-width:44rem; font-size:19px; }
.blog-post--note .blog-post-excerpt { max-width:44rem; }
.blog-post--photo_essay { max-width:940px; }
.blog-post--photo_essay .blog-post-body figure { margin:42px 0; }
.blog-post--photo_essay .blog-post-body figure img { max-height:none; }
.blog-post--curated_list .blog-post-body ol { counter-reset:item; list-style:none; padding:0; }
.blog-post--curated_list .blog-post-body ol li { counter-increment:item; position:relative; padding:16px 16px 16px 64px; border-top:1px solid rgba(27,24,16,.16); }
.blog-post--curated_list .blog-post-body ol li::before { content:counter(item, decimal-leading-zero); position:absolute; left:0; color:var(--orange-ink); font-weight:700; }
.blog-gallery { display:grid; grid-template-columns:repeat(2,1fr); gap:12px; margin:24px 0; }.blog-gallery img,.blog-card-cover { width:100%; aspect-ratio:4/3; object-fit:cover; }
@media (max-width: 650px) { .blog-post { margin: 28px 14px; padding: 26px; }.blog-gallery { grid-template-columns:1fr; } }

/* Reading progress, in the entry's color. */
.cs-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  z-index: 200;
  background: var(--modal-accent);
  transform: scaleX(0);
  transform-origin: left;
}

/* ── Nav (markup shared with index.html via render.js's navHtml()) ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--black);
  padding: 0 44px;
  /* One centered row whose items share a text baseline (see home.css). */
  display: grid;
  grid-auto-flow: column;
  justify-content: space-between;
  align-items: baseline;
  align-content: center;
  height: 60px;
}
.nav-name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 16px;
  color: var(--paper);
  text-decoration: none;
  display: flex;
  align-items: baseline;
  gap: 10px;
  white-space: nowrap;
}
.nav-mark { width: 26px; height: 26px; display: block; object-fit: contain; }
.nav-links { display: flex; align-items: baseline; gap: 28px; list-style: none; }
.nav-links a {
  position: relative;
  font-size: 13px;
  font-weight: 500;
  color: var(--paper);
  opacity: 0.75;
  text-decoration: none;
  transition: opacity 0.2s;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--orange);
  transition: width 0.25s ease;
}
/* Hover only where a real pointer exists (a tap leaves :hover stuck on phones). */
@media (hover: hover) {
  .nav-links a:hover { opacity: 1; }
  .nav-links a:hover::after { width: 100%; }
}
/* Bigger tap target (see home.css): an invisible box around each short word,
   and touch screens get the underline/color at once instead of a crawl. */
.nav-links a { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.nav-links a::before { content: ''; position: absolute; inset: -18px -6px; }
@media (hover: none) {
  .nav-links a, .nav-links a::after { transition: none; }
}
/* "You are here": Blog stays highlighted on every /blog/ page. */
.nav-links a.is-active { color: var(--orange); opacity: 1; }
.nav-links a.is-active::after { width: 100%; }
/* The last item is the mailto icon — see index.html for why. */
.nav-links li:last-child a {
  color: var(--orange);
  opacity: 1;
  font-weight: 600;
}
/* Icon sits on the text baseline; ::before keeps a comfortable tap target. */
.nav-contact a { position: relative; display: inline-block; line-height: 0; }
.nav-contact a::before { content: ''; position: absolute; inset: -18px -5px; }
.nav-contact a::after { content: none; }
.nav-contact svg { position: relative; top: 3px; }

/* ── Banner: the modal's banner, scaled up to page size ── */
.modal-header.cs-banner {
  height: clamp(300px, 36vw, 420px);
  align-items: flex-start;
  padding: 128px max(44px, calc((100vw - var(--max)) / 2)) 0;
}
.cs-banner .modal-header-slab {
  left: -6%;
  top: 26%;
  width: 82%;
  height: 90%;
  transform: skewY(-6deg);
  animation-duration: 0.8s;
}
.cs-banner .modal-header-chips { gap: 12px; }
.cs-banner .modal-header-chip { font-size: 14px; padding: 7px 16px; }
.cs-banner .modal-header-squiggle {
  top: 70px;
  right: 9%;
  width: 280px;
  height: 28px;
}
.cs-banner .modal-header-squiggle path { stroke-width: 5; }
.cs-banner .modal-header-sticker {
  top: 130px;
  bottom: auto;
  right: calc(9% + 70px);
  width: 110px;
  height: 110px;
  animation-delay: 1s;
}
.cs-banner .modal-header-sticker-mark { inset: 16px; }
/* A slow bob once it's landed, so the page feels alive while reading. */
@keyframes csStickerBob {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -6px; }
}
.cs-banner .modal-header-sticker {
  animation: modalStickerIn 0.5s cubic-bezier(0.34,1.56,0.64,1) 1s both,
             csStickerBob 5s ease-in-out 1.6s infinite;
}

/* ── The paper card, overlapping the banner ── */
.cs-main {
  max-width: var(--max);
  margin: -150px auto 0;
  padding: 0 24px 80px;
  position: relative;
  z-index: 1;
}
.cs-card {
  background: var(--paper);
  color: var(--ink);
  padding: 44px 48px 52px;
  box-shadow: 0 24px 60px rgba(0,0,0,.45);
  /* Swings in tilted like the homepage cards, then settles flat: a card
     this tall would push past the screen edge (and slant long lines of
     text) if it stayed rotated. */
  animation: csCardIn 0.7s cubic-bezier(0.22,1,0.36,1) 0.35s both;
}
.cs-card.blog-post {
  max-width: none;
  margin: 0;
  border-radius: 0;
}
.cs-card.blog-post h1 {
  font: 700 clamp(34px, 5vw, 52px)/1.05 var(--serif);
  letter-spacing: -0.02em;
  margin: 0 0 18px;
}
.cs-card.blog-post .blog-post-excerpt {
  font-size: 19px;
  line-height: 1.55;
  font-weight: 500;
  color: var(--ink);
  border-left: 4px solid var(--modal-accent);
  padding-left: 18px;
  margin: 8px 0 28px;
}
.cs-card.blog-post .blog-post-cover {
  margin: 6px 0 30px;
}
@keyframes csCardIn {
  from { opacity: 0; transform: translateY(40px) rotate(-2.5deg); }
  to   { opacity: 1; transform: none; }
}
.cs-kicker {
  font-family: var(--hand);
  font-size: 24px;
  line-height: 1;
  color: var(--orange-ink);
  margin-bottom: 10px;
  transform: rotate(-2deg);
  transform-origin: left;
}
.cs-title.modal-title {
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.cs-card .modal-logo { width: 128px; height: 96px; }
.cs-date { margin: 2px 0 16px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: rgba(27,24,16,.6); }
.cs-summary {
  font-size: 19px;
  line-height: 1.55;
  font-weight: 500;
  color: var(--ink);
  border-left: 4px solid var(--modal-accent);
  padding-left: 18px;
  margin: 8px 0 22px;
}
/* Case-study header: the top row has the back link on the left and the
   "Visit ..." link on the right; the title row has the title on the left and
   the logo on the right, vertically centered on the title. */
.cs-card { position: relative; }
.cs-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-bottom: 20px;
}
.cs-top .cs-back-top { margin: 0; }
.cs-top .cs-visit { margin: 0 0 0 auto; white-space: nowrap; }
.cs-card .cs-heading {
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.cs-card .cs-heading .cs-title { flex: 1 1 auto; min-width: 0; }
/* The logo image has 9px of built-in padding, and a square icon is narrower
   than its box; pull it back and right-align the artwork so its right edge
   lines up with the Visit link above. */
.cs-card .cs-heading .modal-logo { object-position: right center; }
.cs-card .cs-heading > .modal-logo,
.cs-card .cs-heading > .modal-logo-link { margin-right: -9px; }
.cs-visit {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid var(--orange);
}
.cs-visit:hover { color: var(--orange-ink); }

/* Section text a notch bigger than in the modal — this is a reading page. */
.cs-sections { margin-top: 12px; }
.cs-sections .modal-section-label { font-size: 12px; margin-top: 34px; }
.cs-sections .modal-problem,
.cs-sections .modal-outcome,
.cs-sections .modal-bullets li,
.cs-sections .modal-ext-body { font-size: 16.5px; line-height: 1.75; }
.cs-sections .modal-ext-heading { font-size: 26px; }
.cs-sections .modal-stats { margin: 34px 0 10px; gap: 14px; }
.cs-sections .modal-stat-tile {
  padding: 22px 14px;
  background: var(--black);
  border: none;
  transform: rotate(var(--tilt, -1.5deg));
}
.cs-sections .modal-stat-tile:nth-child(even) { --tilt: 1.5deg; }
.cs-sections .modal-stat-num { font-size: 34px; color: var(--modal-accent); }
.cs-sections .modal-stat-label { color: var(--sub); font-size: 12px; }

/* ── Blog index (/blog/) ── */
/* The original tilted paper card and accent slabs, expanded across the page. */
.blog-hero {
  position: relative;
  overflow: hidden;
  padding: 112px 44px 0;
  min-height: 540px;
}
.blog-hero-inner {
  position: relative;
  max-width: 1320px;
  margin: 0 auto;
  padding: 36px 0 116px;
}
.blog-hero-slab { position: absolute; pointer-events: none; z-index: 0; }
.blog-hero-slab--a {
  left: -72px;
  top: -12px;
  width: min(65vw, 830px);
  height: 350px;
  background: var(--orange);
  transform: skewY(-6deg) rotate(-3deg);
}
.blog-hero-card-wrap {
  position: relative;
  display: inline-block;
}
.blog-hero-slab--b {
  right: -125px;
  top: 132px;
  width: min(66vw, 1050px);
  height: 340px;
  background: var(--blue);
  transform: skewY(5deg) rotate(4deg);
}
.blog-hero-card {
  position: relative;
  z-index: 1;
  display: inline-block;
  max-width: min(78vw, 770px);
  background: var(--paper);
  color: var(--ink);
  padding: 44px 58px 52px;
  transform: rotate(-1.4deg);
  box-shadow: 0 24px 54px rgba(0,0,0,.4);
}
.blog-hero-kicker {
  font-family: var(--hand);
  font-size: 22px;
  line-height: 1;
  color: var(--orange-ink);
  margin-bottom: 8px;
  transform: rotate(1deg);
  display: inline-block;
}
.blog-hero-title {
  font-family: var(--serif);
  font-size: clamp(54px, 7vw, 88px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}
.blog-hero-sub {
  font-size: clamp(16px, 1.6vw, 20px);
  line-height: 1.55;
  color: rgba(27,24,16,.7);
  max-width: 580px;
  white-space: pre-line;
}
.blog-main { max-width: 1320px; margin: 0 auto; padding: 0 44px 100px; }
.blog-featured { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, 1fr); gap: 24px; margin-bottom: 58px; }
.blog-supporting { display: grid; gap: 16px; }
.blog-tile { --card-accent: var(--orange); display: grid; grid-template-columns: 140px minmax(0, 1fr); color: var(--ink); background: var(--card-accent); text-decoration: none; box-shadow: 0 12px 28px rgba(0,0,0,.28); overflow: hidden; transition: transform .2s ease, box-shadow .2s ease; }
/* Cards rest straight (there are many text-heavy ones, so a permanent tilt
   would be busy) and get the homepage cards' playful treatment on hover: a
   small alternating tilt, a lift and a deeper shadow. Phones have no hover, so
   the card crossing the middle of the screen gets it instead (.is-centered,
   toggled by the small script in blog-index-template.html). Keyboard focus
   lifts without tilting. */
.blog-tile { --tilt: -1deg; transition: transform .25s ease, box-shadow .25s ease; }
.blog-tile:nth-child(even) { --tilt: 1deg; }
.blog-tile--lead { --tilt: -.6deg; }
.blog-tile:focus-visible { transform: translateY(-5px); box-shadow: 0 20px 34px rgba(0,0,0,.38); }
@media (hover: hover) {
  .blog-tile:hover { transform: rotate(var(--tilt)) translateY(-6px); box-shadow: 0 22px 38px rgba(0,0,0,.4); }
}
@media (hover: none) {
  .blog-tile.is-centered { transform: rotate(var(--tilt)) translateY(-6px); box-shadow: 0 22px 38px rgba(0,0,0,.4); }
}
@media (prefers-reduced-motion: reduce) {
  .blog-tile:hover, .blog-tile.is-centered { transform: translateY(-5px); }
}
.blog-tile:focus-visible { outline: 3px solid var(--orange); outline-offset: 4px; }
.blog-card-image, .blog-card-art { display: block; min-height: 100%; background: var(--card-accent); }
.blog-card-image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-art { background: linear-gradient(145deg, transparent 42%, rgba(255,255,255,.26) 43% 49%, transparent 50%), var(--card-accent); }
.blog-tile-content { display: flex; flex-direction: column; align-items: flex-start; padding: 22px 24px; background: var(--paper); }
.blog-tile-meta { color: var(--orange-ink); font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.blog-video-badge { display: inline-block; margin-left: 9px; color: var(--ink); }
.blog-tile-title { font: 700 clamp(22px,2.5vw,32px)/1.14 var(--serif); margin: 8px 0 12px; }
.blog-tile-excerpt { font-size: 14px; line-height: 1.6; color: rgba(27,24,16,.75); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.blog-tile-action { font-size: 13px; font-weight: 700; margin-top: auto; padding-top: 18px; }
.blog-tile--lead { grid-template-columns: 1fr; height: 100%; }
.blog-tile--lead .blog-card-image, .blog-tile--lead .blog-card-art { min-height: 230px; max-height: 300px; }
.blog-tile--lead .blog-tile-content { padding: 30px 34px 34px; }
.blog-tile--lead .blog-tile-title { font-size: clamp(32px,3.5vw,48px); }
.blog-tile--lead .blog-tile-excerpt { font-size: 16px; -webkit-line-clamp: 4; }
.blog-tile--supporting { grid-template-columns: 110px minmax(0,1fr); }
.blog-tile--supporting .blog-tile-title { font-size: clamp(20px,2vw,26px); }
.blog-tile--supporting .blog-tile-excerpt { -webkit-line-clamp: 2; }
.blog-tile--supporting .blog-tile-content { padding: 17px 21px; }
.blog-jump { padding: 0 0 18px; margin-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,.22); }
.blog-jump span { color: var(--orange); font-family: var(--hand); font-size: 24px; }
.blog-section { padding-top: 48px; scroll-margin-top: 64px; }
.blog-section-heading { display: flex; justify-content: space-between; gap: 20px; align-items: end; margin-bottom: 24px; }
.blog-section h2 { font: 700 clamp(30px,4vw,44px)/1.1 var(--serif); }
.blog-section-heading p:last-child { color: var(--sub); margin-top: 8px; }
.blog-section-count { font-size: 12px; white-space: nowrap; color: var(--sub); }
.blog-section-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
.blog-tile--note { grid-template-columns: 14px minmax(0,1fr); }
.blog-tile--note .blog-card-image, .blog-tile--note .blog-card-art { width: 14px; }
.blog-tile--photo_essay .blog-card-image, .blog-tile--photo_essay .blog-card-art { min-height: 230px; }
.blog-tile--regular.blog-tile--photo_essay { grid-template-columns: 1fr; }
.blog-tile--regular.blog-tile--curated_list { border-top: 6px solid var(--card-accent); }
.blog-tile--regular.blog-tile--curated_list .blog-card-art { display: none; }
.blog-empty { font: 600 24px var(--serif); padding: 40px 0 100px; }
@media (max-width: 1000px) { .blog-featured { grid-template-columns: 1fr; }.blog-supporting { grid-template-columns: repeat(3,minmax(0,1fr)); }.blog-tile--supporting { grid-template-columns: 1fr; }.blog-tile--supporting .blog-card-image,.blog-tile--supporting .blog-card-art { min-height: 140px; max-height: 180px; } }

/* ── More case studies ── */
.cs-more { margin-top: 72px; }
.cs-more-title {
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 600;
  margin-bottom: 26px;
}
.cs-more-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 26px 22px;
}
.cs-more-card {
  --tilt: -1.5deg;
  display: block;
  position: relative;
  background: var(--paper);
  color: var(--ink);
  text-decoration: none;
  padding: 20px 20px 18px;
  border-top: 6px solid var(--card-accent, var(--orange));
  box-shadow: 0 12px 26px rgba(0,0,0,.35);
  transform: rotate(var(--tilt));
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.cs-more-card:nth-child(3n+2) { --tilt: 1deg; }
.cs-more-card:nth-child(3n+3) { --tilt: -0.5deg; }
.cs-more-card:hover,
.cs-more-card:focus-visible {
  transform: rotate(calc(var(--tilt) * -0.4)) translateY(-6px);
  box-shadow: 0 20px 36px rgba(0,0,0,.45);
}
.cs-more-kicker {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange-ink);
}
.cs-more-name {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  margin: 4px 0 6px;
}
.cs-more-go { font-size: 13px; font-weight: 600; }
.cs-more-kicker,
.cs-more-name,
.cs-more-go { display: block; }

.cs-back { margin-top: 56px; text-align: center; }
.cs-back a {
  font-family: var(--hand);
  font-size: 26px;
  color: var(--paper);
  text-decoration: none;
  border-bottom: 2px solid var(--orange);
}
.cs-back a:hover { color: var(--orange); }
.cs-back-top { margin-bottom: 20px; }
.cs-back-top a { color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 700; border-bottom: 2px solid var(--orange); }
.cs-back-top a:hover { color: var(--orange-ink); }
.blog-post .cs-back a { color: var(--ink); }
.blog-post .cs-back a:hover { color: var(--orange-ink); }

/* ── Footer (mirrors index.html) ── */
footer {
  padding: 26px 44px;
  background: var(--black);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-name {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 600;
  color: var(--paper);
  text-decoration: none;
}
.footer-links { display: flex; gap: 26px; }
/* Each contact link stacks its logo above the label. */
.footer-links a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--paper);
  opacity: .8;
  text-decoration: none;
}
.footer-links a:hover { opacity: 1; }
.footer-icon { display: block; line-height: 0; }
.footer-icon svg { width: 20px; height: 20px; }

/* ── Scroll-in motion (added by the page script, so no-JS readers see
   everything) ── */
/* On article pages .cs-sections holds one tall .blog-post-body wrapper: it is
   never hidden itself (that made the text wait until a big share of the
   whole body was on screen, very late on a phone); its paragraphs and
   images fade in one by one instead. */
.cs-animate .cs-sections > *:not(.blog-post-body),
.cs-animate .blog-post-body > *,
.cs-animate .cs-more-card {
  opacity: 0;
  translate: 0 28px;
  transition: opacity 0.6s ease, translate 0.6s cubic-bezier(0.22,1,0.36,1);
}
.cs-animate .cs-sections .modal-stat-tile {
  opacity: 0;
  scale: 0.8;
  transition: opacity 0.45s ease, scale 0.5s cubic-bezier(0.34,1.56,0.64,1);
}
.cs-animate .cs-sections > .is-in,
.cs-animate .blog-post-body > .is-in,
.cs-animate .cs-sections .modal-stat-tile.is-in,
.cs-animate .cs-more-card.is-in { opacity: 1; translate: 0 0; scale: 1; }
/* The stats row itself shows at once; its tiles pop in one by one. */
.cs-animate .cs-sections > .modal-stats { opacity: 1; translate: 0 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cs-card,
  .cs-banner .modal-header-sticker { animation: none; }
}

@media (max-width: 900px) {
  nav { padding: 0 16px; }
  .nav-name { font-size: 15px; }
  .nav-links { gap: 14px; }
  .nav-links a { font-size: 11.5px; }
  .nav-mark { display: none; }
  .nav-desktop-only { display: none; }
  .modal-header.cs-banner { height: 280px; padding: 96px 20px 0; }
  .cs-banner .modal-header-slab { width: 104%; }
  .cs-banner .modal-header-squiggle { left: 20px; right: auto; top: 40px; width: 140px; height: 14px; }
  .cs-banner .modal-header-sticker { top: 34px; bottom: auto; right: 22px; width: 58px; height: 58px; }
  .cs-banner .modal-header-sticker-mark { inset: 10px; }
  .cs-banner .modal-header-chip { font-size: 11.5px; padding: 5px 11px; }
  .cs-banner .modal-header-chips { padding-right: 80px; }
  .cs-main { margin-top: -110px; padding: 0 12px 64px; }
  .cs-card { padding: 30px 22px 36px; }
  .cs-card .modal-logo { width: 84px; height: 64px; padding: 6px; }
  .cs-card .cs-heading > .modal-logo,
  .cs-card .cs-heading > .modal-logo-link { margin-right: -6px; }
  .blog-hero { padding: 88px 20px 0; min-height: 0; }
  .blog-hero-inner { padding: 15px 0 75px; }
  .blog-hero-slab--a { width: 75%; height: 210px; left: -20px; top: -20px; }
  .blog-hero-slab--b { width: 55%; height: 155px; right: -18px; top: auto; bottom: 34px; }
  /* Let the paper card fill the narrow screen while slabs stay behind it. */
  .blog-hero-card-wrap { display: block; width: 100%; }
  .blog-hero-card { padding: 26px 24px 30px; max-width: 100%; }
  .blog-hero-sub { font-size: 15px; }
  .blog-main { padding: 0 20px 72px; }
  .blog-supporting, .blog-section-grid { grid-template-columns: 1fr; }
  .blog-tile--supporting { grid-template-columns: 105px minmax(0,1fr); }
  .blog-tile--supporting .blog-card-image,.blog-tile--supporting .blog-card-art { min-height: 100%; max-height: none; }
  .blog-tile--regular { grid-template-columns: 95px minmax(0,1fr); }
  .blog-tile-content { padding: 18px; }
  .blog-tile--lead .blog-card-image,.blog-tile--lead .blog-card-art { min-height: 170px; }
  .blog-tile--lead .blog-tile-content { padding: 23px; }
  .blog-section-heading { align-items: start; }
  .cs-summary { font-size: 17px; }
  .cs-sections .modal-stat-num { font-size: 26px; }
  footer { flex-direction: column; gap: 16px; padding: 24px 20px; text-align: center; }
}

/* Narrow phones: see index.html for why "Augustine" goes first. */
@media (max-width: 400px) {
  .nav-name-last { display: none; }
  nav { padding: 0 14px; }
  .nav-links { gap: 12px; }
}
