/*
 * The RolePond look (rolepond DESIGN.md and src/app/globals.css): a grey canvas, white cards,
 * Inter, slate greys and near-black ink actions. Theme colours are RGB channels so the dark
 * theme can swap them; .dark is set on <html> by the script in base.njk.
 */

:root {
  color-scheme: light;
  --c-ink: 11 18 32;
  --c-on-ink: 255 255 255;
  --c-canvas: 246 247 249;
  --c-surface: 255 255 255;
  --c-slate-50: 248 250 252;
  --c-slate-100: 241 245 249;
  --c-slate-200: 226 232 240;
  --c-slate-300: 203 213 225;
  --c-slate-400: 148 163 184;
  /* A touch darker than Tailwind's #64748B so meta text passes 4.5:1 on the canvas and grey chips */
  --c-slate-500: 90 104 127;
  --c-slate-600: 71 85 105;
  --c-slate-700: 51 65 85;
  --c-slate-800: 30 41 59;

  --deep-pond: #0b3440;

  /* Chart series, checked with the dataviz validator against the light and dark surfaces */
  --chart-1: #3b6fd8;
  --chart-2: #e0577f;
  --night-pond: #071c26;

  --shadow-xs: 0 1px 2px rgb(15 23 42 / 0.05);
  --shadow-card: 0 1px 2px rgb(15 23 42 / 0.04), 0 2px 8px -2px rgb(15 23 42 / 0.05);
  --shadow-hover: 0 4px 12px -4px rgb(15 23 42 / 0.06);

  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* Slate runs the other way: 50 to 300 are fills and borders a step up from the surface, 400 up get lighter as text. */
.dark {
  color-scheme: dark;
  --c-ink: 236 239 244;
  --c-on-ink: 12 16 23;
  --c-canvas: 12 16 23;
  --c-surface: 20 26 36;
  --c-slate-50: 26 33 45;
  --c-slate-100: 32 40 54;
  --c-slate-200: 43 53 69;
  --c-slate-300: 59 71 90;
  --c-slate-400: 128 140 160;
  --c-slate-500: 146 157 176;
  --c-slate-600: 172 182 198;
  --c-slate-700: 199 207 219;
  --c-slate-800: 221 226 234;
  --chart-1: #4f7fe3;
  --chart-2: #e35f88;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.35s;
  animation-timing-function: ease-in-out;
}

/* Base */

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-optical-sizing: auto;
  font-feature-settings: 'cv11', 'ss03';
  color: rgb(var(--c-ink));
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: rgb(var(--c-canvas));
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  color: rgb(var(--c-slate-600));
}

main {
  flex: 1;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: rgb(var(--c-ink));
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}

button,
.button,
.topics__item,
.navbar__link {
  user-select: none;
  -webkit-user-select: none;
}

:focus-visible {
  outline: 2px solid rgb(var(--c-ink) / 0.7);
  outline-offset: 2px;
  border-radius: 6px;
}

/* Stroke icons (Lucide paths, 1.75 stroke); the footer art and covers draw their own fills */
svg:not(.footer__art-svg):not(.cover):not(.stages__pad):not(.share__logo) {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 50;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgb(var(--c-surface));
  font-size: 14px;
  font-weight: 500;
  color: rgb(var(--c-ink));
  box-shadow: var(--shadow-card);
}

.skip-link:focus {
  top: 16px;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: 16px;
}

@media (min-width: 640px) {
  .container {
    padding-inline: 24px;
  }
}

/* Buttons: pills, primary in ink */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: background-color 150ms, box-shadow 150ms, color 150ms;
}

@media (min-width: 640px) {
  .button {
    height: 36px;
  }
}

.button--primary {
  background: rgb(var(--c-ink));
  color: rgb(var(--c-on-ink));
  box-shadow: var(--shadow-xs);
}

.button--primary:hover {
  background: rgb(var(--c-ink) / 0.85);
}

.button--secondary {
  background: rgb(var(--c-surface));
  color: rgb(var(--c-ink));
  box-shadow: var(--shadow-xs), inset 0 0 0 1px rgb(var(--c-slate-200));
}

.button--secondary:hover {
  background: rgb(var(--c-slate-50));
}

.button--block {
  width: 100%;
}

/* Header: sticky, translucent canvas */

.navbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgb(var(--c-canvas) / 0.8);
  box-shadow: 0 1px 0 rgb(var(--c-slate-200) / 0.7);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.navbar__inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 64px;
}

.navbar__home,
.navbar__logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  flex-shrink: 0;
  border-radius: 8px;
}

.navbar__home img,
.navbar__logo img {
  height: 28px;
  width: auto;
}

.logo-dark,
.dark .logo-light {
  display: none;
}

.dark .logo-dark {
  display: block;
}

.navbar__divider {
  width: 1px;
  height: 20px;
  background: rgb(var(--c-slate-300));
}

.navbar__section {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: rgb(var(--c-ink));
}

a.navbar__section {
  border-radius: 6px;
  transition: color 150ms;
}

a.navbar__section:hover {
  color: rgb(var(--c-slate-600));
}

.navbar__links {
  display: none;
  align-items: center;
  gap: 2px;
  margin-left: 12px;
}

.navbar__link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-size: 13.5px;
  font-weight: 500;
  color: rgb(var(--c-slate-600));
  transition: color 150ms, background-color 150ms;
}

.navbar__link:hover {
  color: rgb(var(--c-ink));
}

.jobs-menu {
  position: relative;
}

.jobs-menu__button {
  padding-right: 10px;
}

.jobs-menu__button svg {
  width: 14px;
  height: 14px;
  transition: transform 150ms;
}

.jobs-menu__button[aria-expanded='true'] {
  background: rgb(var(--c-slate-200) / 0.7);
  color: rgb(var(--c-ink));
}

.jobs-menu__button[aria-expanded='true'] svg {
  transform: rotate(180deg);
}

.jobs-menu__panel {
  position: absolute;
  top: 48px;
  left: 0;
  z-index: 40;
  width: 19rem;
  padding: 6px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.06), 0 12px 32px -8px rgb(15 23 42 / 0.14);
}

/* Fills the gap under the button, so moving the pointer down onto the panel doesn't close it */
.jobs-menu__panel::before {
  content: '';
  position: absolute;
  top: -14px;
  left: 0;
  right: 0;
  height: 14px;
}

.jobs-menu__panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.jobs-menu__row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 12px;
  transition: background-color 150ms;
}

.jobs-menu__row:hover {
  background: rgb(var(--c-slate-100));
}

.jobs-menu__icon {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: rgb(var(--c-slate-100));
  color: rgb(var(--c-slate-600));
}

.jobs-menu__icon svg {
  width: 16px;
  height: 16px;
}

.jobs-menu__label {
  display: block;
  font-size: 13.5px;
  font-weight: 500;
  color: rgb(var(--c-ink));
}

.jobs-menu__detail {
  display: block;
  font-size: 12px;
  line-height: 1.4;
  color: rgb(var(--c-slate-500));
}

.jobs-menu__popular {
  margin-top: 6px;
  padding: 10px 10px 8px;
  border-top: 1px solid rgb(var(--c-slate-100));
}

.jobs-menu__popular p {
  font-size: 12px;
  font-weight: 500;
  color: rgb(var(--c-slate-500));
}

.jobs-menu__popular ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px !important;
}

.jobs-menu__popular a {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgb(var(--c-slate-50));
  box-shadow: inset 0 0 0 1px rgb(var(--c-slate-200));
  font-size: 12.5px;
  font-weight: 500;
  color: rgb(var(--c-slate-700));
  transition: background-color 150ms, color 150ms;
}

.jobs-menu__popular a:hover {
  background: rgb(var(--c-slate-100));
  color: rgb(var(--c-ink));
}

.navbar__menu-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgb(var(--c-slate-600));
}

.navbar__menu-button:hover {
  background: rgb(var(--c-slate-100));
  color: rgb(var(--c-ink));
}

.navbar__menu-button svg {
  width: 20px;
  height: 20px;
}

.navbar__mobile {
  padding-block: 8px 16px;
  border-top: 1px solid rgb(var(--c-slate-200) / 0.7);
}

.navbar__mobile .container {
  display: flex;
  flex-direction: column;
}

.navbar__mobile-link {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  color: rgb(var(--c-slate-700));
}

.navbar__mobile-link:hover {
  background: rgb(var(--c-slate-100));
  color: rgb(var(--c-ink));
}

@media (min-width: 900px) {
  .navbar__links {
    display: flex;
  }

  .navbar__menu-button,
  .navbar__mobile {
    display: none !important;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Signed in or out, from <html data-auth="in"> set before the first paint */
html:not([data-auth='in']) .auth-in,
html[data-auth='in'] .auth-out {
  display: none !important;
}

/* The account menu: the site's avatar button and menu */
.account-menu {
  position: relative;
}

.account-menu__button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 44px;
  padding: 0 8px 0 4px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgb(var(--c-ink));
  transition: background-color 150ms;
}

@media (min-width: 640px) {
  .account-menu__button {
    height: 40px;
  }
}

.account-menu__button:hover,
.account-menu__button[aria-expanded='true'] {
  background: rgb(var(--c-slate-200) / 0.7);
}

.account-menu__chevron {
  width: 14px;
  height: 14px;
  transition: transform 150ms;
}

.account-menu__button[aria-expanded='true'] .account-menu__chevron {
  transform: rotate(180deg);
}

.account-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: 999px;
  background: rgb(var(--c-surface));
  box-shadow: inset 0 0 0 1px rgb(var(--c-slate-200));
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  color: rgb(var(--c-ink));
}

.account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.account-avatar svg {
  width: 16px;
  height: 16px;
  color: rgb(var(--c-slate-600));
}

.account-menu__panel {
  position: absolute;
  top: 48px;
  right: 0;
  z-index: 40;
  width: 16rem;
  padding: 6px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.06), 0 12px 32px -8px rgb(15 23 42 / 0.14);
}

.account-menu__panel ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.account-menu__group {
  margin: 6px 0 0;
  padding-top: 6px;
  border-top: 1px solid rgb(var(--c-slate-100));
}

.account-menu__group p {
  padding: 6px 10px 4px;
  font-size: 12px;
  font-weight: 500;
  color: rgb(var(--c-slate-500));
}

.account-menu__row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  height: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  font-size: 13.5px;
  text-align: left;
  color: rgb(var(--c-ink));
  transition: background-color 150ms;
}

.account-menu__row:hover {
  background: rgb(var(--c-slate-100));
}

.account-menu__row svg {
  width: 16px;
  height: 16px;
  color: rgb(var(--c-slate-500));
}

.account-menu__detail {
  margin-left: auto;
  font-size: 12px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.navbar__end {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.navbar__back-long {
  display: none;
}

.navbar__back svg {
  width: 14px;
  height: 14px;
}

@media (min-width: 640px) {
  .navbar__back-long {
    display: inline;
  }
}

/* Blog titles are a step bolder than the site's 600 (Ernest, 2 November 2026) */
.blog-hero__title,
.page-title,
.post-header__title,
.lead-post__title {
  font-weight: 700;
}

/* Page header: breadcrumbs, the h1, one line of meta */

.page {
  padding-block: 32px 0;
}

@media (min-width: 640px) {
  .page {
    padding-top: 48px;
  }
}

.page-header {
  margin-bottom: 28px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
  font-size: 13px;
  color: rgb(var(--c-slate-500));
}

.breadcrumbs a {
  transition: color 150ms;
}

.breadcrumbs a:hover {
  color: rgb(var(--c-ink));
}

.page-title {
  max-width: 800px;
  font-size: 1.75rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

@media (min-width: 640px) {
  .page-title {
    font-size: 2rem;
  }
}

.page-title__faint {
  color: rgb(var(--c-slate-500));
}

.page-meta {
  margin-top: 8px;
  font-size: 14px;
  color: rgb(var(--c-slate-500));
}


/* Micro label above titles: 12px, sentence case, never all caps */

.eyebrow {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 500;
  color: rgb(var(--c-slate-500));
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
}

/* Drafts (drafts/) are flagged in amber; they only exist in npm run dev */

.draft-flag {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 14px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgb(245 158 11 / 0.14);
  font-size: 12.5px;
  font-weight: 500;
  color: #92400e;
}

.dark .draft-flag {
  color: #fbbf24;
}

.draft-flag--small {
  margin: 0 2px 0 0;
  padding: 1px 8px;
  font-size: 12px;
}

/* Covers: generated SVG (_lib/cover.js) in a rounded frame */

.cover {
  display: block;
  width: 100%;
  height: 100%;
}

.lead-post__cover,
.post-card__cover,
.post-row__cover,
.post-cover {
  overflow: hidden;
  border-radius: 12px;
  aspect-ratio: 1200 / 630;
  background: rgb(var(--c-slate-100));
}

/* Home: a big editorial title with the lede beside it */

.blog-hero {
  display: grid;
  gap: 16px;
  margin-bottom: 32px;
}

@media (min-width: 900px) {
  .blog-hero {
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: end;
    gap: 48px;
    margin-bottom: 40px;
  }
}

.blog-hero__title {
  font-size: 2.25rem;
  line-height: 1.04;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

@media (min-width: 640px) {
  .blog-hero__title {
    font-size: 3.25rem;
  }
}

.blog-hero__lede {
  font-size: 15px;
  color: rgb(var(--c-slate-600));
}

.button svg {
  width: 15px;
  height: 15px;
  color: rgb(var(--c-slate-500));
}

/* The latest post: cover and text side by side in one card, the whole card is the link */

.lead-post {
  /* Wider than the page column on big screens (up to 1160px), the same width on small ones */
  --lead-width: max(100%, min(1160px, calc(100vw - 48px)));
  width: var(--lead-width);
  margin-inline: calc((100% - var(--lead-width)) / 2);
  position: relative;
  display: grid;
  gap: 20px;
  padding: 12px 12px 24px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 20px;
  background: rgb(var(--c-surface));
  box-shadow: var(--shadow-card);
  transition: box-shadow 150ms;
}

.lead-post:hover {
  box-shadow: var(--shadow-card), var(--shadow-hover);
}

.lead-post__body {
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 12px;
  padding-inline: 12px;
}

@media (min-width: 900px) {
  .lead-post {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 40px;
    padding: 12px 40px 12px 12px;
  }

  /* The cover fills the card's height, so the inset is 12px on every side whatever the text's length */
  .lead-post__cover {
    aspect-ratio: auto;
    height: 100%;
    min-height: 400px;
  }

  .lead-post__body {
    padding: 40px 0;
  }
}

.lead-post__title {
  font-size: 1.625rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

@media (min-width: 640px) {
  .lead-post__title {
    font-size: 2rem;
  }
}

.lead-post__title a::after,
.post-card__title a::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.lead-post__title a:focus-visible,
.post-card__title a:focus-visible,
.post-row__title a:focus-visible {
  outline: none;
}

.lead-post:has(a:focus-visible),
.post-card:has(.post-card__title a:focus-visible),
.post-row:has(a:focus-visible) {
  outline: 2px solid rgb(var(--c-ink) / 0.7);
  outline-offset: 2px;
}

.lead-post__description {
  font-size: 15.5px;
  color: rgb(var(--c-slate-600));
}

.lead-post__meta {
  font-size: 13px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.lead-post__more,
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  font-size: 14px;
  font-weight: 500;
  color: rgb(var(--c-ink));
}

.lead-post__more svg,
.link-arrow svg {
  width: 15px;
  height: 15px;
  transition: transform 150ms;
}

.lead-post:hover .lead-post__more svg,
.link-arrow:hover svg {
  transform: translateX(3px);
}

.section-title {
  margin: 56px 0 16px;
  font-size: 1.125rem;
  line-height: 1.35;
}

/* Archive: topics on the left, post rows on the right */

.archive {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  margin-top: 56px;
}

.page-header + .archive {
  margin-top: 0;
}

/* "Topics" and the list's heading share one line, so both columns start level */
.archive__title,
.topics__title {
  height: 24px;
  margin: 0 0 14px;
  line-height: 24px;
}

.archive__title {
  font-size: 1.125rem;
}

@media (min-width: 900px) {
  .archive {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 40px;
    align-items: start;
  }

  .topics {
    position: sticky;
    top: 88px;
  }
}

.topics__title {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  color: rgb(var(--c-slate-500));
}

.topics__list {
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 0 0 4px;
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}

.topics__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 500;
  color: rgb(var(--c-slate-600));
  background: rgb(var(--c-surface));
  box-shadow: inset 0 0 0 1px rgb(var(--c-slate-200));
  transition: color 150ms, background-color 150ms;
}

.topics__item:hover {
  color: rgb(var(--c-ink));
}

.topics__item[aria-current='page'] {
  background: rgb(var(--c-ink));
  color: rgb(var(--c-on-ink));
  box-shadow: none;
}

.topics__count {
  font-size: 12px;
  font-weight: 500;
  color: inherit;
  opacity: 0.65;
  font-variant-numeric: tabular-nums;
}

@media (min-width: 900px) {
  .topics__list {
    flex-direction: column;
    gap: 2px;
    overflow: visible;
  }

  /* The pill reaches into the gutter so the names line up with "Topics" above them */
  .topics__list {
    margin-left: -12px !important;
  }

  .topics__item {
    height: 34px;
    padding: 0 12px;
    background: transparent;
    box-shadow: none;
  }

  .topics__item[aria-current='page'] {
    background: rgb(var(--c-slate-200) / 0.7);
    color: rgb(var(--c-ink));
  }

  .topics__count {
    color: rgb(var(--c-slate-500));
    opacity: 1;
  }
}

.post-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.post-row {
  position: relative;
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  padding: 16px;
  transition: background-color 150ms;
}

.post-row + .post-row {
  border-top: 1px solid rgb(var(--c-slate-100));
}

.post-row:hover {
  background: rgb(var(--c-slate-50));
}

@media (min-width: 640px) {
  .post-row {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 24px;
    padding: 20px;
    align-items: center;
  }
}

.post-row__cover {
  border-radius: 10px;
}

.post-row__body {
  display: grid;
  gap: 6px;
}

.post-row__title {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

@media (min-width: 640px) {
  .post-row__title {
    font-size: 1.25rem;
  }
}

.post-row__title a::after {
  content: '';
  position: absolute;
  inset: 0;
}

.post-row__description {
  display: none;
  font-size: 14px;
  color: rgb(var(--c-slate-600));
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 640px) {
  .post-row__description {
    display: -webkit-box;
  }
}

.post-row__meta,
.post-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  font-size: 12.5px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

/* Cover cards (Keep reading) */

.post-grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 640px) {
  .post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .post-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.post-card {
  position: relative;
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 8px 8px 18px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  transition: box-shadow 150ms;
}

.post-card:hover {
  box-shadow: var(--shadow-hover);
}

.post-card__cover {
  border-radius: 10px;
}

.post-card__body {
  display: grid;
  gap: 6px;
  padding-inline: 10px;
}

.post-card__title {
  font-size: 1rem;
  line-height: 1.35;
  text-wrap: balance;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 9px;
  border-radius: 6px;
  background: rgb(var(--c-slate-100));
  font-size: 12.5px;
  font-weight: 500;
  color: rgb(var(--c-slate-600));
  transition: background-color 150ms, color 150ms;
}

.tag:hover {
  background: rgb(var(--c-slate-200));
  color: rgb(var(--c-ink));
}

.pagination {
  display: flex;
  gap: 8px;
  margin-top: 24px;
}

.pagination__next {
  margin-left: auto;
}

/* Post page: a big plain header, the cover, then the text with its contents beside it */

.post-header {
  padding-block: 32px 28px;
}

@media (min-width: 640px) {
  .post-header {
    padding-block: 56px 36px;
  }
}

.post-header__title {
  max-width: 880px;
  font-size: 2rem;
  line-height: 1.08;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

@media (min-width: 640px) {
  .post-header__title {
    font-size: 2.875rem;
  }
}

.post-header__lede {
  max-width: 680px;
  margin-top: 16px;
  font-size: 17px;
  line-height: 1.6;
  color: rgb(var(--c-slate-600));
  text-wrap: pretty;
}

.byline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}

.byline__avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

.byline__name {
  font-size: 14px;
  font-weight: 500;
  color: rgb(var(--c-ink));
}

.byline__meta {
  font-size: 13px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.post-cover {
  border-radius: 20px;
}

@media (min-width: 640px) {
  .post-cover {
    aspect-ratio: 1200 / 520;
  }
}

.post-layout {
  display: grid;
  gap: 32px;
  padding-top: 40px;
}

@media (min-width: 1024px) {
  .post-layout {
    grid-template-columns: 200px minmax(0, 680px);
    gap: 72px;
    padding-top: 56px;
  }

  .post-aside {
    position: sticky;
    top: 96px;
    align-self: start;
  }
}

.post-aside {
  display: grid;
  gap: 28px;
  align-content: start;
}

.contents__title {
  margin-bottom: 10px;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0;
  color: rgb(var(--c-slate-500));
}

.contents ol {
  margin: 0;
  padding: 0 0 0 12px;
  list-style: none;
  border-left: 1px solid rgb(var(--c-slate-200));
}

.contents li + li {
  margin-top: 8px;
}

.contents a {
  display: block;
  font-size: 13.5px;
  line-height: 1.4;
  color: rgb(var(--c-slate-600));
  transition: color 150ms;
}

.contents a:hover {
  color: rgb(var(--c-ink));
}

/* The section being read: ink, with the rail darkened beside it */
.contents a {
  position: relative;
}

.contents a[aria-current='true'] {
  font-weight: 500;
  color: rgb(var(--c-ink));
}

.contents a[aria-current='true']::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -13px;
  width: 2px;
  border-radius: 2px;
  background: rgb(var(--c-ink));
}

/* Headings focused from the contents list show no focus ring; the scroll already shows where you are */
.prose [id]:focus {
  outline: none;
}

/* Phones and tablets keep the topics but not the contents list, which sits above the text */
@media (max-width: 1023px) {
  .contents {
    display: none;
  }
}

/* Share: the sticky aside on desktop; after the text on phones and tablets, where the aside sits above it */

.share__buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.share__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: rgb(var(--c-slate-100));
  color: rgb(var(--c-slate-600));
  cursor: pointer;
  transition: background-color 150ms, color 150ms;
}

.share__button:hover {
  background: rgb(var(--c-slate-200));
  color: rgb(var(--c-ink));
}

.share__button svg {
  width: 17px;
  height: 17px;
}

.share__logo {
  fill: currentColor;
}

.share__button .share__logo {
  width: 15px;
  height: 15px;
}

.share__status {
  min-height: 1lh;
  margin-top: 8px;
  font-size: 12.5px;
  color: rgb(var(--c-slate-500));
}

.share--end {
  padding-top: 28px;
  border-top: 1px solid rgb(var(--c-slate-200));
}

@media (max-width: 1023px) {
  .share--aside {
    display: none;
  }
}

@media (min-width: 1024px) {
  .share--end {
    display: none;
  }
}

/* Call to action after a post, on the deep pond */

.cta {
  position: relative;
  display: grid;
  gap: 20px;
  margin-top: 64px;
  padding: 32px 24px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--deep-pond);
  color: #fff;
}

@media (min-width: 768px) {
  .cta {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    padding: 40px 48px;
  }
}

.cta__art {
  position: absolute;
  inset: 0;
  opacity: 0.9;
  -webkit-mask-image: linear-gradient(to right, transparent 20%, #000 75%);
  mask-image: linear-gradient(to right, transparent 20%, #000 75%);
}

.cta__art .cover {
  width: 100%;
  height: 100%;
}

.cta__body,
.cta__actions {
  position: relative;
}

.cta__title {
  font-size: 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: #fff;
}

.cta__text {
  margin-top: 6px;
  font-size: 15px;
  color: rgb(255 255 255 / 0.72);
}

.cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.button--light {
  background: #fff;
  color: #0b1220;
}

.button--light:hover {
  background: rgb(255 255 255 / 0.88);
}

.button--glass {
  background: rgb(255 255 255 / 0.1);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.18);
}

.button--glass:hover {
  background: rgb(255 255 255 / 0.16);
}

.cta :focus-visible {
  outline-color: rgb(255 255 255 / 0.8);
}

.keep-reading__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-top: 64px;
}

.keep-reading__head .section-title {
  margin: 0 0 16px;
}

/* /covers/: every motif in every tone */

.cover-swatches {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.cover-swatch {
  margin: 0;
}

.cover-swatch figcaption {
  margin-top: 6px;
  font-size: 12.5px;
  color: rgb(var(--c-slate-500));
}

/* Topics: one card per topic with its latest cover and posts */

.topic-grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 768px) {
  .topic-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.topic-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 16px;
  padding: 8px 8px 20px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  box-shadow: var(--shadow-card);
}

.topic-card__cover {
  display: block;
  overflow: hidden;
  border-radius: 10px;
  aspect-ratio: 3 / 1;
  background: rgb(var(--c-slate-100));
}

.topic-card__body {
  display: grid;
  gap: 12px;
  padding-inline: 12px;
}

.topic-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.topic-card__name {
  font-size: 1.125rem;
  line-height: 1.3;
}

.topic-card__name a:hover {
  color: rgb(var(--c-slate-600));
}

.topic-card__count {
  flex-shrink: 0;
  font-size: 13px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.topic-card__posts {
  margin: 0;
  padding: 0;
  list-style: none;
}

.topic-card__posts li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-block: 10px;
  border-top: 1px solid rgb(var(--c-slate-100));
}

.topic-card__posts a {
  font-size: 14.5px;
  font-weight: 500;
  line-height: 1.4;
  color: rgb(var(--c-ink));
  transition: color 150ms;
}

.topic-card__posts a:hover {
  color: rgb(var(--c-slate-600));
}

.topic-card__posts time {
  flex-shrink: 0;
  font-size: 12.5px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

/* Lists inside a card: label left, value and chevron right, the whole row is the link */


.row-list {
  margin: 0;
  padding: 0;
  list-style: none;
  overflow: hidden;
}

.row-list li + li {
  border-top: 1px solid rgb(var(--c-slate-100));
}

.row-list__row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 0 16px 0 20px;
  transition: background-color 150ms;
}

.row-list__row:hover {
  background: rgb(var(--c-slate-50));
}

.row-list__label {
  font-size: 15px;
  font-weight: 500;
  color: rgb(var(--c-ink));
}

.row-list__value {
  margin-left: auto;
  font-size: 13px;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.row-list__chevron {
  width: 16px;
  height: 16px;
  color: rgb(var(--c-slate-400));
}

/* Article text */

.prose {
  font-size: 16.5px;
  line-height: 1.75;
  color: rgb(var(--c-slate-700));
  overflow-wrap: break-word;
}

.card.prose {
  padding: 24px 20px;
}

@media (min-width: 640px) {
  .card.prose {
    padding: 40px 48px;
  }
}

/* Anchored headings clear the sticky header */
.prose [id] {
  scroll-margin-top: 88px;
}

.prose--narrow {
  max-width: 760px;
}

.prose > * {
  max-width: 680px;
}

.prose > * + * {
  margin-top: 1.1em;
}

.prose > :first-child {
  margin-top: 0;
}

.prose h1 {
  margin-top: 2em;
  font-size: 1.625rem;
  line-height: 1.25;
  letter-spacing: -0.025em;
}

.prose h2 {
  margin-top: 2em;
  font-size: 1.375rem;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.prose h3 {
  margin-top: 1.75em;
  font-size: 1.125rem;
  line-height: 1.35;
}

.prose h4,
.prose h5,
.prose h6 {
  margin-top: 1.5em;
  font-size: 1rem;
  line-height: 1.4;
}

.prose h2 + *,
.prose h3 + *,
.prose h4 + *,
.prose h5 + *,
.prose h6 + * {
  margin-top: 0.6em;
}

.prose a {
  color: rgb(var(--c-ink));
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: rgb(var(--c-slate-300));
  text-underline-offset: 3px;
  transition: text-decoration-color 150ms;
}

.prose a:hover {
  text-decoration-color: rgb(var(--c-ink));
}

.prose strong {
  font-weight: 600;
  color: rgb(var(--c-ink));
}

.prose ul,
.prose ol {
  padding-left: 1.4em;
}

.prose li + li {
  margin-top: 0.35em;
}

.prose li::marker {
  color: rgb(var(--c-slate-400));
}

.prose blockquote {
  margin-inline: 0;
  padding: 2px 0 2px 18px;
  border-left: 3px solid rgb(var(--c-slate-200));
  color: rgb(var(--c-slate-600));
}

.prose hr {
  border: 0;
  border-top: 1px solid rgb(var(--c-slate-100));
  margin-block: 2em;
}

.prose figure {
  margin: 2em 0 0;
}

.prose figure + * {
  margin-top: 2em;
}

.prose figcaption {
  margin-top: 10px;
  font-size: 13.5px;
  line-height: 1.5;
  color: rgb(var(--c-slate-500));
}

.prose img {
  display: block;
  border: 1px solid rgb(var(--c-slate-200) / 0.8);
  border-radius: 16px;
}

.prose code {
  padding: 2px 6px;
  border-radius: 6px;
  background: rgb(var(--c-slate-100));
  font-family: var(--mono);
  font-size: 0.85em;
  color: rgb(var(--c-ink));
}

.prose pre {
  max-width: 100%;
  padding: 16px 18px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 12px;
  background: rgb(var(--c-slate-50));
  overflow-x: auto;
  font-size: 14px;
  line-height: 1.6;
}

.prose pre code {
  padding: 0;
  background: none;
  font-size: inherit;
}

.prose table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  font-size: 14px;
}

.prose th,
.prose td {
  padding: 8px 14px 8px 0;
  border-bottom: 1px solid rgb(var(--c-slate-100));
  text-align: left;
}

.prose th {
  font-weight: 600;
  color: rgb(var(--c-ink));
  border-bottom-color: rgb(var(--c-slate-200));
}

/* Charts in posts (_lib/charts.js) */

.prose .chart {
  max-width: 680px;
  margin: 2em 0;
  padding: 20px;
  border: 1px solid rgb(var(--c-slate-200) / 0.7);
  border-radius: 16px;
  background: rgb(var(--c-surface));
  box-shadow: var(--shadow-card);
}

.prose .chart__title {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  color: rgb(var(--c-ink));
}

.chart__source {
  margin-top: 14px !important;
  font-size: 12.5px;
  line-height: 1.5;
  color: rgb(var(--c-slate-500));
}

.chart__data {
  margin-top: 8px;
  font-size: 13px;
}

.chart__data summary {
  cursor: pointer;
  width: fit-content;
  color: rgb(var(--c-slate-600));
  font-weight: 500;
}

.chart__data table {
  display: table;
  width: 100%;
  margin-top: 8px;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.chart__legend {
  display: flex;
  gap: 16px;
  margin-top: 10px;
  font-size: 13px;
  color: rgb(var(--c-slate-600));
}

.chart__legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.chart__swatch {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.chart__swatch--1,
.lines__dot--1 {
  background: var(--chart-1);
}

.chart__swatch--2,
.lines__dot--2 {
  background: var(--chart-2);
}

/* Stat tiles */

.chart__tiles {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

@media (min-width: 560px) {
  .chart__tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.stat-tile {
  padding: 14px 16px;
  border-radius: 12px;
  background: rgb(var(--c-slate-50));
}

.stat-tile p {
  margin: 0 !important;
}

.stat-tile__label {
  font-size: 13px;
  color: rgb(var(--c-slate-500));
}

.stat-tile__values {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-top: 4px !important;
  font-variant-numeric: tabular-nums;
}

.stat-tile__from {
  font-size: 1.25rem;
  font-weight: 500;
  color: rgb(var(--c-slate-500));
}

.stat-tile__arrow {
  color: rgb(var(--c-slate-400));
}

.stat-tile__to {
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: rgb(var(--c-ink));
}

.stat-tile__meta {
  margin-top: 4px !important;
  font-size: 12.5px;
  line-height: 1.5;
  color: rgb(var(--c-slate-500));
}

.stat-tile__change {
  font-weight: 600;
  color: rgb(var(--c-ink));
}

/* Bars: thin columns from the baseline, rounded at the data end, a value on each */

.bars {
  margin-top: 16px;
  padding-left: 32px;
}

.bars__plot {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  align-items: end;
  gap: 12px;
  height: 200px;
  margin-top: 28px;
  border-bottom: 1px solid rgb(var(--c-slate-300));
}

.bars__grid {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid rgb(var(--c-slate-100));
}

.bars__grid span,
.lines__grid span {
  position: absolute;
  right: calc(100% + 8px);
  top: -8px;
  font-size: 11.5px;
  line-height: 1;
  color: rgb(var(--c-slate-500));
  font-variant-numeric: tabular-nums;
}

.bars__col {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  height: 100%;
}

.bars__bar {
  position: relative;
  width: min(48px, 70%);
  border-radius: 4px 4px 0 0;
  background: var(--chart-1);
}

.bars__value {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 13px;
  font-weight: 600;
  color: rgb(var(--c-ink));
  font-variant-numeric: tabular-nums;
}

.bars__labels {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 12px;
  margin-top: 8px;
  font-size: 12.5px;
  text-align: center;
  color: rgb(var(--c-slate-500));
}

/* Stages: hand-drawn pads with their names */

.stages {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: 16px 8px;
  margin: 16px 0 0 !important;
  padding: 0 !important;
  list-style: none;
}

.stages__step {
  display: grid;
  grid-template-rows: 72px auto auto;
  align-content: start;
  justify-items: center;
  gap: 2px;
  margin: 0 !important;
  text-align: center;
}

.stages__step::marker {
  content: none;
}

.stages__pad {
  width: 72px;
  height: 72px;
}

.stages__step--faded .stages__pad {
  opacity: 0.4;
  filter: grayscale(0.6);
}

.stages__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  color: rgb(var(--c-ink));
}

.stages__line {
  font-size: 12.5px;
  line-height: 1.4;
  color: rgb(var(--c-slate-500));
}

/* Lines: 2px strokes, 8px points with a surface ring, the latest value labelled at each end */

.lines {
  margin-top: 14px;
  padding: 0 64px 0 36px;
}

.lines__plot {
  position: relative;
  height: 220px;
  border-bottom: 1px solid rgb(var(--c-slate-300));
}

.lines__grid {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid rgb(var(--c-slate-100));
}

.lines__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.lines__path {
  fill: none;
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.lines__path--1 {
  stroke: var(--chart-1);
}

.lines__path--2 {
  stroke: var(--chart-2);
}

.lines__dot {
  position: absolute;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgb(var(--c-surface));
  transform: translate(-50%, -50%);
}

.lines__dot::after {
  content: '';
  position: absolute;
  inset: -8px;
}

.lines__end {
  position: absolute;
  left: calc(100% + 10px);
  transform: translateY(-50%);
  white-space: nowrap;
  font-size: 12.5px;
  font-weight: 600;
  color: rgb(var(--c-ink));
  font-variant-numeric: tabular-nums;
}

.lines__x {
  position: relative;
  height: 24px;
  font-size: 12.5px;
  color: rgb(var(--c-slate-500));
}

.lines__x span {
  position: absolute;
  top: 6px;
  transform: translateX(-50%);
}

/* Footer on the deep pond, with "Pond at dusk" along the bottom (rolepond SiteFooter and FooterArt) */

.footer {
  position: relative;
  margin-top: 80px;
  overflow: hidden;
  background: var(--deep-pond);
  color: #fff;
}

.dark .footer {
  background: var(--night-pond);
}

.footer__art {
  pointer-events: none;
  position: absolute;
  inset: auto 0 0;
  height: 240px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 38%);
  mask-image: linear-gradient(to bottom, transparent, #000 38%);
}

.footer__art-svg {
  position: absolute;
  bottom: 0;
  left: calc((100% - 875px) * 0.18);
  width: 875px;
  height: 100%;
}

@media (min-width: 640px) {
  .footer__art {
    height: max(300px, 27.44vw);
  }

  .footer__art-svg {
    left: 0;
    width: 100%;
  }
}

.footer__inner {
  position: relative;
  padding-block: 56px 150px;
}

@media (min-width: 640px) {
  .footer__inner {
    padding-bottom: max(210px, 17.5vw);
  }
}

.footer__grid {
  display: grid;
  gap: 40px;
}

@media (min-width: 1024px) {
  .footer__grid {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 32px;
  }
}

.footer__tagline {
  max-width: 16rem;
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.6;
  color: rgb(255 255 255 / 0.7);
}

.footer__columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px 24px;
}

@media (min-width: 640px) {
  .footer__columns {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.footer__heading {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  color: #fff;
}

.footer__list {
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}

.footer__list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-size: 13px;
  color: rgb(255 255 255 / 0.7);
  transition: color 150ms;
}

.footer__list a:hover {
  color: #fff;
}

@media (min-width: 640px) {
  .footer__list {
    margin-top: 12px;
  }

  .footer__list li + li {
    margin-top: 8px;
  }

  .footer__list a {
    display: inline;
    min-height: 0;
  }
}

.footer__bottom {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 40px;
  font-size: 12px;
  color: rgb(255 255 255 / 0.6);
}

@media (min-width: 640px) {
  .footer__bottom {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer :focus-visible {
  outline-color: rgb(255 255 255 / 0.7);
}

.theme-switch {
  display: inline-flex;
  align-self: flex-start;
  padding: 2px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.1);
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.1);
}

.theme-switch button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgb(255 255 255 / 0.6);
  transition: color 150ms, background-color 150ms;
}

.theme-switch button:hover {
  color: #fff;
}

.theme-switch button[aria-pressed='true'] {
  background: rgb(255 255 255 / 0.15);
  color: #fff;
}

.theme-switch svg {
  width: 16px;
  height: 16px;
}

@media (min-width: 640px) {
  .theme-switch {
    align-self: auto;
  }

  .theme-switch button {
    width: 32px;
    height: 32px;
  }

  .theme-switch svg {
    width: 14px;
    height: 14px;
  }
}

/* Footer pond: the frog blinks, the flags wave; dusk in the light theme, night in the dark one */

.frog-eye {
  transform-box: fill-box;
  transform-origin: center;
  animation: frog-blink 5.5s ease-in-out infinite;
}

.pond-flag {
  transform-box: fill-box;
  transform-origin: 0% 50%;
  animation: pond-flag-wave 3.2s ease-in-out infinite alternate;
}

.pond-sun,
.pond-moon {
  transition: transform 1.1s cubic-bezier(0.45, 0, 0.25, 1);
}

.pond-moon {
  transform: translateY(96px);
}

.pond-sun {
  transition-delay: 0.25s;
}

.dark .pond-sun {
  transform: translateY(60px);
  transition-delay: 0s;
}

.dark .pond-moon {
  transform: none;
  transition-delay: 0.25s;
}

/* Narrow screens only see the left of the art; slide the sun and moon in beside the frog */
@media (max-width: 767px) {
  .pond-sun,
  .pond-moon,
  .pond-glint {
    translate: -540px 0;
  }
}

.pond-night-stars {
  opacity: 0;
}

.dark .pond-night-stars {
  opacity: 1;
}

.pond-sky,
.pond-water,
.pond-pads,
.pond-glint rect {
  transition: fill 1.2s ease;
}

.pond-waves {
  transition: stroke 1.2s ease;
}

.pond-stars,
.pond-night-stars,
.pond-glint {
  transition: opacity 1.2s ease;
}

.dark .pond-sky {
  fill: #071c26;
}

.dark .pond-stars {
  opacity: 0.6;
}

.dark .pond-water {
  fill: #092d38;
}

.dark .pond-waves {
  stroke: #144552;
}

.dark .pond-pads {
  fill: #349159;
}

.dark .pond-glint {
  fill: #e9eef2;
  opacity: 0.45;
}

.dark .pond-glint rect {
  fill: inherit;
}

@keyframes frog-blink {
  0%,
  92%,
  100% {
    transform: scaleY(1);
  }

  95% {
    transform: scaleY(0.1);
  }
}

@keyframes pond-flag-wave {
  from {
    transform: skewY(-3deg) scaleX(1);
  }

  to {
    transform: skewY(3deg) scaleX(0.94);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .frog-eye,
  .pond-flag {
    animation: none;
  }
}
