/* jbbres.com — site styles. No external resources; fonts are self-hosted (SIL OFL). */

@font-face {
  font-family: "IBM Plex Sans";
  src: url("fonts/plex-sans-var.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("fonts/plex-sans-italic-var.woff2") format("woff2");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Zilla Slab";
  src: url("fonts/zilla-slab-semibold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Zilla Slab";
  src: url("fonts/zilla-slab-bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ------------------------------------------------------------- tokens */
:root {
  --navy: #0f1d2e;
  --navy-2: #172a40;
  --navy-3: #22384f;
  --on-navy: #eef2f6;
  --on-navy-2: #a9b6c6;
  --rust: #c75323;          /* brand tile */
  --rust-ink: #b2441a;      /* rust for text on light backgrounds (AA) */
  --rust-on-navy: #f08a5d;  /* rust for text on navy (AA) */

  --bg: #ffffff;
  --bg-2: #f3f5f8;
  --text: #0f1d2e;
  --text-2: #3b4b5f;
  --text-3: #57677b;
  --rule: #dbe1e8;
  --link: var(--rust-ink);
  --focus: #2f6fb0;
  --tag-bg: #eef1f5;
  --tag-article-bg: #fbe9e1;
  --tag-article-text: #8d3412;
  --blank-bg: #eef1f5;      /* card without an image */
  --blank-rule: #dfe4ea;

  --font-display: "Zilla Slab", Rockwell, "Roboto Slab", Georgia, serif;
  --font-text: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 10px;
  --radius-portrait: 50%;
  --wrap: 1180px;
  --narrow: 44rem;
  --gutter: clamp(16px, 4vw, 40px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1622;
    --bg-2: #122133;
    --text: #e8edf3;
    --text-2: #c1ccd8;
    --text-3: #98a7b8;
    --rule: #233549;
    --link: #f39a72;
    --focus: #7fb2e8;
    --tag-bg: #1a2c41;
    --tag-article-bg: #3a2218;
    --tag-article-text: #f5b493;
    --blank-bg: #172a40;
    --blank-rule: #22384f;
    color-scheme: dark;
  }
}

/* --------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.6;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; letter-spacing: -0.005em; margin: 0; }
p { margin: 0; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--bg); color: var(--text); padding: 10px 14px; border-radius: 6px;
}
.skip:focus { top: 12px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.wrap-narrow { max-width: calc(var(--narrow) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding-top: clamp(40px, 6vw, 72px); padding-bottom: clamp(8px, 2vw, 16px); }

/* ---------------------------------------------------------- masthead */
.masthead { background: var(--navy); color: var(--on-navy); }
/* Page headers: navy with flowing wave lines on the right (header-waves.svg,
   published with a fingerprinted name by the builder). The lines fade out
   towards the left and the bottom, so text stays on calm navy. */
.hero, .pagehead, .entry__head, .profile {
  background: var(--navy) url("header-waves.134d739861cd.svg") no-repeat right top / 1600px auto;
}
@media (max-width: 760px) {
  .hero, .pagehead, .entry__head, .profile { background-size: 1100px auto; }
}
.masthead__row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--on-navy); text-decoration: none; flex: none; }
.brand .logo { display: block; border-radius: 8px; }
.brand__name { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; letter-spacing: 0.005em; }
.mainnav ul { display: flex; gap: clamp(4px, 1.6vw, 18px); list-style: none; margin: 0; padding: 0; }
.mainnav a {
  display: block; padding: 8px 6px; color: var(--on-navy-2); text-decoration: none;
  font-size: 0.97rem; font-weight: 500; border-bottom: 2px solid transparent;
}
.mainnav a:hover { color: var(--on-navy); }
.mainnav a[aria-current="page"] { color: var(--on-navy); border-bottom-color: var(--rust); }
.masthead :focus-visible { outline-color: #9cc4ef; }

@media (max-width: 640px) {
  .brand__name { display: none; }
  .mainnav a { font-size: 0.93rem; padding: 8px 4px; }
}

/* -------------------------------------------------------------- hero */
.hero { color: var(--on-navy); padding: clamp(28px, 6vw, 72px) 0 clamp(48px, 7vw, 96px); overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.8fr); gap: clamp(28px, 6vw, 88px); align-items: center; }
.hero__name {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(3rem, 1.6rem + 6.2vw, 6.4rem); line-height: 0.95; letter-spacing: -0.02em;
  color: #fff;
}
.hero__family { display: block; }
.hero__role { margin-top: 22px; font-size: clamp(1.15rem, 1rem + 0.6vw, 1.45rem); font-weight: 500; color: var(--on-navy); }
.hero__lede { margin-top: 14px; max-width: 34em; font-size: 1.08rem; color: var(--on-navy-2); line-height: 1.65; }
.hero__actions { margin-top: 30px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero__portrait { position: relative; justify-self: end; width: min(100% - 16px, 330px); margin: 8px; }
.hero__portrait img, .profile__portrait img {
  position: relative; display: block; width: 100%; aspect-ratio: 1; object-fit: cover;
  border-radius: var(--radius-portrait);
  /* Thin rust ring, set slightly apart from the photo. */
  outline: 2px solid var(--rust); outline-offset: 6px;
}

@media (max-width: 760px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__portrait { order: -1; justify-self: start; width: 132px; margin: 6px 0 0 6px; }
  .hero__portrait img { outline-offset: 4px; }
}

/* ----------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 10px 20px;
  border-radius: 8px; font-weight: 600; font-size: 1rem; text-decoration: none; border: 2px solid transparent;
}
.btn--primary { background: var(--rust); color: #fff; }
.btn--primary:hover { background: #ad4419; }
.btn--quiet { color: var(--on-navy); border-color: rgba(238, 242, 246, 0.35); }
.btn--quiet:hover { border-color: var(--on-navy); }
.prose .btn--primary, .section .btn--primary { color: #fff; }

/* ---------------------------------------------------------- sections */
.section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 22px; padding-bottom: 12px; border-bottom: 2px solid var(--text); }
.section__head h2 { font-size: clamp(1.6rem, 1.3rem + 1vw, 2.1rem); }
.section__more { font-weight: 500; white-space: nowrap; }

/* ------------------------------------------------------------- cards */
.featured { display: grid; grid-template-columns: 1.55fr 1fr; grid-template-rows: auto auto auto 1fr; gap: 28px 36px; }
.featured .card { align-self: start; }
.featured .card--lead { grid-row: 1 / -1; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 36px; }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.card__media { display: block; aspect-ratio: 16 / 10; border-radius: var(--radius); overflow: hidden; background: var(--bg-2); }
.card__media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s ease; }
.card__media:hover img { transform: scale(1.02); }
.card__media--blank { display: grid; place-items: center; background: var(--blank-bg); box-shadow: inset 0 0 0 1px var(--blank-rule); }
.card__body { display: flex; flex-direction: column; gap: 8px; }
.card__title { font-size: 1.3rem; line-height: 1.2; }
.card__title a { color: var(--text); text-decoration: none; }
.card__title a:hover { color: var(--link); text-decoration: underline; text-decoration-thickness: 2px; }
.card__summary { color: var(--text-2); font-size: 0.98rem; line-height: 1.55; }
.card--lead .card__title { font-size: clamp(1.6rem, 1.2rem + 1.2vw, 2.15rem); }
.card--lead .card__summary { font-size: 1.05rem; }
.featured .card:not(.card--lead) { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 18px; align-items: start; }
.featured .card:not(.card--lead) .card__summary { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

@media (max-width: 900px) {
  .featured { grid-template-columns: 1fr; }
  .featured .card--lead { grid-row: auto; }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .grid, .grid--3 { grid-template-columns: 1fr; }
  .featured .card:not(.card--lead) { grid-template-columns: 112px minmax(0, 1fr); gap: 14px; }
  .featured .card:not(.card--lead) .card__media { aspect-ratio: 1; }
  .featured .card:not(.card--lead) .card__summary { display: none; }
  .featured .card:not(.card--lead) .card__title { font-size: 1.12rem; }
}

/* --------------------------------------------------------------- meta */
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; color: var(--text-3); font-size: 0.88rem; }
.meta__sep { width: 6px; height: 6px; border-radius: 1.5px; background: var(--rust); flex: none; }

/* ------------------------------------------------------ list / stream */
.columns { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 900px) { .columns { grid-template-columns: 1fr; } }

.stream { list-style: none; margin: 0; padding: 0; }
.row { display: grid; grid-template-columns: 7.2rem minmax(0, 1fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--rule); }
.row__date { color: var(--text-3); font-size: 0.88rem; padding-top: 0.2em; font-variant-numeric: tabular-nums; }
.row__title { color: var(--text); font-weight: 500; font-size: 1.05rem; line-height: 1.4; text-decoration: none; }
.row__title:hover { color: var(--link); text-decoration: underline; }
.row--article .row__title { font-family: var(--font-display); font-weight: 600; font-size: 1.22rem; line-height: 1.25; }
.row__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.tag { display: inline-block; font-size: 0.78rem; line-height: 1.5; padding: 1px 8px; border-radius: 4px; background: var(--tag-bg); color: var(--text-2); }
.tag--article { background: var(--tag-article-bg); color: var(--tag-article-text); font-weight: 600; }
.tag--link { text-decoration: none; }
.tag--link:hover { background: var(--rust); color: #fff; }

@media (max-width: 520px) {
  .row { grid-template-columns: 1fr; gap: 2px; }
}

.pagehead { color: var(--on-navy); padding: clamp(32px, 6vw, 64px) 0 clamp(32px, 5vw, 56px); }
.pagehead__title { font-size: clamp(2.4rem, 1.6rem + 3.4vw, 4rem); font-weight: 700; color: #fff; letter-spacing: -0.015em; }
.pagehead__intro { margin-top: 14px; max-width: 40em; color: var(--on-navy-2); font-size: 1.08rem; }
.pagehead__intro a { color: var(--rust-on-navy); }

.years ul { display: flex; flex-wrap: wrap; gap: 6px 14px; list-style: none; padding: 0; margin: 0 0 8px; }
.years a { font-variant-numeric: tabular-nums; font-weight: 500; text-decoration: none; }
.years a:hover { text-decoration: underline; }
.year { margin-top: 28px; }
.year__title { font-size: 1.5rem; padding-bottom: 8px; border-bottom: 2px solid var(--text); }

/* -------------------------------------------------------------- aside */
.aside { position: sticky; top: 24px; }
.aside__title { font-size: 1.25rem; margin: 0 0 12px; padding-bottom: 10px; border-bottom: 2px solid var(--text); }
.aside__title:not(:first-child) { margin-top: 36px; }
.aside__text { color: var(--text-2); font-size: 0.97rem; margin-bottom: 10px; }
.aside__feed { margin-top: 28px; color: var(--text-3); font-size: 0.9rem; }
@media (max-width: 900px) { .aside { position: static; } }

.topics { list-style: none; margin: 0; padding: 0; }
.topics a { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--rule); color: var(--text); text-decoration: none; }
.topics a:hover { color: var(--link); }
.topics a[aria-current="page"] { color: var(--link); font-weight: 600; }
.topics a[aria-current="page"] span:first-child::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 2px; background: var(--rust); vertical-align: 0.12em; }
.topics__count { color: var(--text-3); font-variant-numeric: tabular-nums; font-size: 0.9rem; }

/* -------------------------------------------------------------- entry */
.entry__head { color: var(--on-navy); padding: clamp(28px, 5vw, 56px) 0 clamp(30px, 5vw, 52px); }
.crumb a { color: var(--on-navy-2); font-size: 0.95rem; font-weight: 500; text-decoration: none; }
.crumb a:hover { color: #fff; text-decoration: underline; }
.entry--article .crumb a::before { content: ""; display: inline-block; width: 9px; height: 9px; margin-right: 9px; border-radius: 2px; background: var(--rust); vertical-align: 0.05em; }
.entry__title { margin-top: 14px; color: #fff; font-size: clamp(2rem, 1.35rem + 2.8vw, 3.15rem); line-height: 1.08; letter-spacing: -0.012em; }
.entry__lede {
  margin-top: 14px; color: var(--on-navy-2); font-size: 1.05rem; line-height: 1.55; max-width: 40em;
  /* Never more than three lines, even if a long summary is entered. */
  display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
@media (max-width: 520px) { .entry__lede { font-size: 0.98rem; } }
.entry__meta { margin-top: 20px; color: var(--on-navy-2); }
.entry__meta a { color: var(--on-navy); }
.entry__body { padding-top: clamp(28px, 5vw, 48px); }
.print-only { display: none; }

/* Print button (articles; shown by print.js) */
.printbtn {
  display: inline-flex; align-items: center; gap: 7px; margin-left: 6px; padding: 3px 11px;
  background: none; color: var(--on-navy); border: 1px solid rgba(238, 242, 246, 0.35); border-radius: 6px;
  font: inherit; font-size: 0.86rem; font-weight: 500; cursor: pointer;
}
.printbtn:hover { border-color: var(--on-navy); }
.printbtn[hidden] { display: none; }
.printbtn:focus-visible { outline-color: #9cc4ef; }

/* "At a glance": key points of an article, collapsed by default */
.glance-wrap { padding-top: clamp(24px, 4vw, 40px); }
.glance-wrap + .entry__body { padding-top: clamp(24px, 4vw, 36px); }
.glance { background: var(--bg-2); border: 1px solid var(--rule); border-left: 4px solid var(--rust); border-radius: var(--radius); }
.glance__summary { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 14px; padding: 14px 48px 14px 20px; cursor: pointer; list-style: none; position: relative; }
.glance__summary::-webkit-details-marker { display: none; }
.glance__summary::after {
  content: ""; position: absolute; right: 20px; top: 50%; width: 9px; height: 9px; margin-top: -7px;
  border-right: 2px solid var(--text-2); border-bottom: 2px solid var(--text-2); transform: rotate(45deg); transition: transform 0.2s ease;
}
.glance[open] .glance__summary::after { transform: rotate(-135deg); margin-top: -1px; }
.glance__summary:hover .glance__title { color: var(--link); }
.glance__title { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; color: var(--text); }
.glance__hint { color: var(--text-3); font-size: 0.88rem; }
.glance__body { padding: 0 22px 18px 20px; font-size: 1.02rem; line-height: 1.6; }
.glance__body ul { margin: 0; }

/* Link at the end of a post */
.linkcard {
  display: grid; grid-template-columns: 176px minmax(0, 1fr); margin-top: 36px; overflow: hidden;
  border: 1px solid var(--rule); border-radius: var(--radius); background: var(--bg); color: var(--text); text-decoration: none;
  transition: border-color 0.2s ease;
}
.linkcard:hover { border-color: var(--rust); }
.linkcard__media { display: block; min-height: 100%; background: var(--bg-2); }
.linkcard__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.linkcard__media--blank { display: grid; place-items: center; color: var(--text-3); min-height: 112px; }
.linkcard__body { display: flex; flex-direction: column; gap: 4px; padding: 16px 20px; min-width: 0; }
.linkcard__site { color: var(--text-3); font-size: 0.82rem; letter-spacing: 0.02em; }
.linkcard__title { font-family: var(--font-display); font-weight: 600; font-size: 1.22rem; line-height: 1.25; }
.linkcard:hover .linkcard__title { color: var(--link); text-decoration: underline; text-decoration-thickness: 2px; }
.linkcard__desc { color: var(--text-2); font-size: 0.95rem; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 560px) {
  .linkcard { grid-template-columns: 1fr; }
  .linkcard__media { aspect-ratio: 1.91 / 1; min-height: 0; }
  .linkcard__media--blank { aspect-ratio: auto; min-height: 56px; }
}

/* Disclaimer at the end of an article */
.disclaimer { margin-top: 44px; }
.disclaimer__label { padding-top: 14px; border-top: 1px solid var(--rule); color: var(--text-3); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.disclaimer__text { margin-top: 6px; color: var(--text-3); font-size: 0.82rem; line-height: 1.55; }
.disclaimer__text p + p { margin-top: 0.6em; }
.disclaimer__text a { color: inherit; }

.entry__foot { padding-top: 24px; padding-bottom: 24px; }
.entry__topics { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 18px 0; border-top: 1px solid var(--rule); }
.entry__topics-label { color: var(--text-3); font-size: 0.9rem; margin-right: 4px; }
.entry__topics .tag { font-size: 0.85rem; padding: 3px 10px; }

.author { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 18px; align-items: center; padding: 22px; margin-top: 8px; background: var(--bg-2); border-radius: var(--radius); }
.author__img { width: 72px; height: 90px; object-fit: cover; border-radius: 10px; }
.author__name { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; }
.author__name a { color: var(--text); text-decoration: none; }
.author__role { color: var(--text-2); font-size: 0.95rem; margin-top: 2px; }
.author__links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 6px; font-size: 0.95rem; font-weight: 500; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 28px; }
.pager__link { display: flex; flex-direction: column; gap: 4px; padding: 16px 0; border-top: 2px solid var(--text); text-decoration: none; color: var(--text); }
.pager__link--newer { grid-column: 2; text-align: right; }
.pager__label { color: var(--text-3); font-size: 0.85rem; }
.pager__title { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; line-height: 1.25; }
.pager__link:hover .pager__title { color: var(--link); text-decoration: underline; }
@media (max-width: 560px) {
  .pager { grid-template-columns: 1fr; }
  .pager__link--newer { grid-column: auto; text-align: left; }
}
.related { padding-bottom: 32px; }

/* --------------------------------------------------------------- prose */
.prose { font-size: 1.125rem; line-height: 1.7; color: var(--text); overflow-wrap: break-word; }
.prose > * + * { margin-top: 1.1em; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: 1.75rem; margin-top: 1.9em; line-height: 1.2; }
.prose h3 { font-size: 1.38rem; margin-top: 1.6em; line-height: 1.25; }
.prose h4, .prose h5, .prose h6 { font-family: var(--font-text); font-size: 1.1rem; font-weight: 600; margin-top: 1.4em; }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: 0.55em; }
.prose ul, .prose ol { padding-left: 1.35em; }
.prose li + li { margin-top: 0.35em; }
.prose li::marker { color: var(--rust); }
.prose blockquote { margin-left: 0; margin-right: 0; padding: 4px 0 4px 22px; border-left: 4px solid var(--rust); color: var(--text-2); font-size: 1.12rem; }
.prose figure { margin: 1.8em 0; }
.prose figure img, .prose p img { display: block; margin: 0 auto; border-radius: 8px; }
.prose code { font-family: var(--font-mono); font-size: 0.88em; padding: 0.1em 0.35em; border-radius: 4px; background: var(--bg-2); }
.prose pre { overflow-x: auto; padding: 16px; border-radius: 8px; background: var(--bg-2); font-size: 0.9rem; line-height: 1.5; }
.prose pre code { padding: 0; background: none; }
.prose hr { border: 0; height: 2px; background: var(--rule); margin: 2.2em 0; }
.prose strong { font-weight: 600; }
.table-wrap { overflow-x: auto; margin: 1.6em 0; border: 1px solid var(--rule); border-radius: 8px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 0.95rem; line-height: 1.45; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid var(--rule); }
.prose th { background: var(--bg-2); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }

/* ----------------------------------------------------------- profile */
.profile { color: var(--on-navy); padding: clamp(32px, 6vw, 72px) 0 clamp(40px, 6vw, 80px); }
.profile__grid { display: grid; grid-template-columns: minmax(0, 316px) minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.profile__portrait { position: relative; width: min(100% - 16px, 300px); margin: 8px; }
.profile__name { font-size: clamp(2.6rem, 1.6rem + 4vw, 4.6rem); font-weight: 700; line-height: 0.98; color: #fff; letter-spacing: -0.02em; }
.profile__role { margin-top: 16px; font-size: clamp(1.08rem, 1rem + 0.45vw, 1.3rem); color: var(--on-navy); max-width: 32em; }
.badges { display: flex; flex-wrap: wrap; gap: 14px; list-style: none; padding: 0; margin: 26px 0 0; }
.badge { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 76px; color: var(--on-navy-2); text-decoration: none; font-size: 0.85rem; font-weight: 600; }
.badge img { width: 64px; height: 64px; object-fit: contain; background: #fff; border-radius: 12px; padding: 4px; }
.badge:hover { color: #fff; }
@media (max-width: 700px) {
  .profile__grid { grid-template-columns: 1fr; }
  .profile__portrait { width: 160px; margin: 6px 0 0 6px; }
  .profile__portrait img { outline-offset: 4px; }
}

/* ------------------------------------------------------------ footer */
.site-footer { margin-top: clamp(48px, 8vw, 96px); background: var(--navy); color: var(--on-navy-2); padding: 36px 0 44px; font-size: 0.95rem; }
.site-footer__row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px 40px; }
.site-footer__name { font-family: var(--font-display); font-weight: 600; color: var(--on-navy); font-size: 1.15rem; }
.site-footer__note { margin-top: 4px; max-width: 34em; }
.site-footer__copyright { margin-top: 10px; font-size: 0.875rem; }
.site-footer__links { display: flex; flex-wrap: wrap; gap: 6px 22px; list-style: none; margin: 0; padding: 0; align-items: flex-start; }
.site-footer a { color: var(--on-navy); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer :focus-visible { outline-color: #9cc4ef; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* -------------------------------------------------------------- print */
/* Articles print like a newspaper article on A4: title first, one column of
   serif text, the key points in a box, and a card about the author with a
   QR code to the site. */
@page { size: A4; margin: 15mm 14mm 17mm; }

@media print {
  :root {
    --bg: #fff; --bg-2: #f2f2f2; --text: #111; --text-2: #333; --text-3: #555; --rule: #b5b5b5;
    --link: #111; --tag-bg: #eee; color-scheme: light;
  }
  html, body { background: #fff; color: #111; }
  body { font-size: 10pt; line-height: 1.45; }
  .masthead, .site-footer, .pager, .related, .aside, .skip, .printbtn { display: none !important; }
  .entry__head, .pagehead, .profile, .hero { background: none; color: #000; }
  .entry__title, .pagehead__title, .profile__name { color: #000; }
  a { color: #111; text-decoration: none; }
  img { break-inside: avoid; }

  .entry .print-only { display: block; }
  .entry .wrap, .entry .wrap-narrow { max-width: none; padding: 0; }
  .entry__head { padding: 0; }
  .crumb, .entry__foot, .glance:not(.glance--print) { display: none !important; }

  .entry__title { margin-top: 0; font-size: 26pt; line-height: 1.08; letter-spacing: -0.01em; }
  .entry__lede { display: block; overflow: visible; -webkit-line-clamp: unset; line-clamp: unset; margin-top: 3mm; color: #333; font-size: 11.5pt; font-style: italic; max-width: none; }
  .entry__meta { margin-top: 3mm; padding-bottom: 2.5mm; border-bottom: 0.75pt solid #111; color: #333; font-size: 8.5pt; }
  .entry__meta a { color: #111; }
  .meta__sep { background: #111; }

  .glance-wrap { padding-top: 0; }
  .entry .glance--print { margin-top: 4mm; padding: 3mm 4mm; background: none; border: 0.75pt solid #111; border-left: 2.5pt solid #111; border-radius: 0; break-inside: avoid; }
  .glance--print .glance__title { font-size: 9.5pt; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
  .glance--print .glance__body { padding: 1.5mm 0 0; font-size: 9.5pt; line-height: 1.45; }
  .glance--print .glance__body li { break-inside: avoid; }

  .entry__body, .glance-wrap + .entry__body {
    padding-top: 5mm;
    font-family: Georgia, "Times New Roman", Times, serif; font-size: 10.5pt; line-height: 1.5;
    text-align: justify; hyphens: auto; orphans: 3; widows: 3;
  }
  .entry__body.prose > * + * { margin-top: 0.75em; }
  .entry__body h2 { font-size: 14pt; margin-top: 1.1em; text-align: left; break-after: avoid; }
  .entry__body h3 { font-size: 12pt; margin-top: 1em; text-align: left; break-after: avoid; }
  .entry__body h4, .entry__body h5, .entry__body h6 { font-size: 10.5pt; margin-top: 0.9em; break-after: avoid; }
  .entry__body h2 + *, .entry__body h3 + *, .entry__body h4 + * { margin-top: 0.4em; }
  .entry__body img { max-height: 100mm; width: auto; margin: 0 auto; border-radius: 0; }
  .entry__body figure, .entry__body pre, .entry__body blockquote, .entry__body li { break-inside: avoid; }
  .entry__body blockquote { border-left: 2pt solid #111; color: #333; font-size: 10pt; padding-left: 4mm; }
  .entry__body .table-wrap { border-color: #999; }
  .entry__body pre, .entry__body code { background: none; border: 0.5pt solid #ccc; }
  .entry--article .entry__body > p:first-child::first-letter {
    float: left; font-family: var(--font-display); font-weight: 600; font-size: 31pt; line-height: 0.82; padding: 1mm 1.5mm 0 0;
  }
  .prose li::marker { color: #111; }

  .entry .linkcard { display: grid; grid-template-columns: 32mm minmax(0, 1fr); margin-top: 5mm; border: 0.75pt solid #111; border-radius: 0; break-inside: avoid; }
  .linkcard__body { padding: 3mm 4mm; }
  .linkcard__title { font-size: 11pt; }
  .linkcard__desc { font-size: 8.5pt; -webkit-line-clamp: unset; line-clamp: unset; display: block; }
  .linkcard__url { font-size: 8pt; word-break: break-all; }

  .disclaimer { margin-top: 5mm; break-inside: avoid; }
  .disclaimer__label { padding-top: 2mm; border-top-color: #999; font-size: 6.5pt; color: #555; }
  .disclaimer__text { margin-top: 1mm; font-size: 7.5pt; line-height: 1.4; color: #444; }

  .entry .printcard {
    display: grid; grid-template-columns: 18mm minmax(0, 1fr) 25mm; gap: 5mm; align-items: center;
    margin-top: 6mm; padding: 4mm; border: 0.75pt solid #111; break-inside: avoid;
  }
  .printcard__img { width: 18mm; height: 22.5mm; object-fit: cover; border-radius: 2mm; }
  .printcard__name { font-family: var(--font-display); font-weight: 600; font-size: 12pt; }
  .printcard__role { margin-top: 0.5mm; color: #333; font-size: 8.5pt; }
  .printcard__links { margin-top: 1.5mm; font-size: 8pt; }
  .printcard__links span { display: block; }
  .printcard__qr { margin: 0; text-align: center; }
  .printcard__qr img { display: block; width: 24mm; height: 24mm; margin: 0 auto; }
  .printcard__qr figcaption { margin-top: 1mm; font-size: 6.5pt; color: #333; }
}
