/* =====================================================================
   Journal: index (/journal/) + post pages (/journal/<slug>/)
   Builds on base.css tokens; no colours are hard-coded outside Glow tweaks.
   ===================================================================== */

/* -------------------------------------------------------------- shared */
.jmeta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px;
  font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: .01em;
}
.jmeta > span { display: inline-flex; align-items: center; gap: 6px; }
.jmeta .i { width: 15px; height: 15px; }
.jmeta__dot { width: 4px; height: 4px; border-radius: 50%; background: var(--line-2); }

/* Pointer-following "Read" bubble (journal.js, fine pointers only).
   Position is lerped by JS through the individual `translate` property (no CSS transition, so no
   double easing); only `scale` transitions, for the grow/shrink. */
.jcursor {
  position: fixed; left: 0; top: 0; z-index: 80; pointer-events: none;
  width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink); color: var(--bg);
  font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase;
  translate: -200px -200px; scale: 0;
  transition: scale .35s var(--ease), background-color .6s var(--ease), color .6s var(--ease);
  will-change: translate, scale;
}
.jcursor.is-on { scale: 1; }
[data-glow="on"] .jcursor { background: var(--glow); color: var(--moss-ink); box-shadow: 0 0 40px -6px color-mix(in srgb, var(--glow) 70%, transparent); }
.has-jcursor .is-cursor, .has-jcursor .is-cursor a { cursor: none; }

/* Split-text headings: the per-word masks (base.css) would clip the Glow-mode text-shadow on <em>
   into hard boxes. Keep the glow off while the words rise, then drop the masks (.split-settled,
   added by journal.js) and let base.css's text-shadow transition fade the glow in. */
.js[data-glow="on"] [data-split]:not(.split-settled) em { text-shadow: none; }
.js [data-split].split-settled .w { overflow: visible; }

/* ================================================================ INDEX */
.jhero { padding: clamp(44px, 7vw, 104px) 0 clamp(36px, 5vw, 72px); }
.jhero__grid {
  display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .85fr);
  gap: 40px clamp(40px, 6vw, 96px); align-items: end;
}
.jhero__title { margin-top: 22px; }
.jhero .lede { margin-top: 26px; max-width: 52ch; }

.jhero__contents .eyebrow { padding-bottom: 14px; border-bottom: 1px solid var(--line-2); }
.jhero__contents ol { margin: 0; }
.jhero__contents a {
  display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 14px; align-items: baseline;
  padding: 15px 0; border-bottom: 1px solid var(--line);
  text-decoration: none; color: var(--ink-2);
  transition: color .3s var(--ease), padding .45s var(--ease);
}
.jhero__num { font-family: var(--font-display); font-style: italic; font-size: 15px; color: var(--muted); transition: color .3s var(--ease); }
.jhero__t { font-family: var(--font-display); font-size: 18px; line-height: 1.25; letter-spacing: -.01em; }
.jhero__min { font-size: 12px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.jhero__contents a:hover { color: var(--ink); padding-left: 8px; }
.jhero__contents a:hover .jhero__num { color: var(--accent); }

/* pull-quote from the latest story (shown while the journal is small) */
.jquote { position: relative; padding: 30px 0 4px; border-top: 1px solid var(--line-2); }
.jquote__mark {
  position: absolute; top: -22px; left: 0; width: 44px; height: 44px; border-radius: 50%;
  display: grid; place-items: center; background: var(--bg); color: var(--accent);
  transition: background-color .6s var(--ease), color .6s var(--ease);
}
.jquote__mark .i { width: 26px; height: 26px; }
.jquote__text p {
  font-family: var(--font-display); font-style: italic; font-weight: 350;
  font-size: clamp(22px, 2.1vw, 29px); line-height: 1.28; letter-spacing: -.015em; color: var(--ink);
  font-variation-settings: "SOFT" 100, "WONK" 1; text-wrap: balance;
}
.jquote__cap { display: grid; gap: 8px; margin-top: 22px; }
.jquote__link {
  justify-self: start; display: inline-flex; align-items: center; gap: 8px;
  font-weight: 800; font-size: 14.5px; line-height: 1.35; color: var(--ink); text-decoration: none;
  background: linear-gradient(currentColor 0 0) 0 100% / 0 1px no-repeat; padding-bottom: 2px;
  transition: background-size .45s var(--ease), color .3s var(--ease);
}
.jquote__link .i { width: 16px; height: 16px; transition: transform .35s var(--ease); }
.jquote__link:hover { background-size: 100% 1px; }
.jquote__link:hover .i { transform: translateX(3px); }
[data-glow="on"] .jquote__mark { filter: drop-shadow(0 0 10px color-mix(in srgb, var(--glow) 60%, transparent)); }

/* featured (latest) story */
.jlist { padding-bottom: clamp(24px, 4vw, 48px); }
.jfeature {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-xl);
  overflow: hidden; isolation: isolate;
  transition: border-color .4s var(--ease), box-shadow .6s var(--ease), background-color .6s var(--ease);
}
.jfeature:hover { border-color: var(--line-2); box-shadow: 0 40px 80px -48px rgba(var(--shadow), .45); }
[data-glow="on"] .jfeature:hover { border-color: color-mix(in srgb, var(--glow) 35%, transparent); box-shadow: 0 0 0 1px color-mix(in srgb, var(--glow) 18%, transparent), 0 40px 90px -40px color-mix(in srgb, var(--glow) 30%, transparent); }
.jfeature__media { position: relative; min-height: 100%; aspect-ratio: 6 / 5; overflow: hidden; background: var(--chip); }
.jfeature__media img, .jcard__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.02); transition: transform 1.4s var(--ease), filter .6s var(--ease);
}
.jfeature:hover .jfeature__media img { transform: scale(1.07); }
.jfeature .badge { top: 20px; left: 20px; }
.jfeature__body {
  display: flex; flex-direction: column; justify-content: center; gap: 20px;
  padding: clamp(28px, 4.4vw, 64px);
}
.jfeature__title { font-size: clamp(32px, 3.5vw, 54px); line-height: 1.02; letter-spacing: -.032em; }
.jfeature__excerpt { color: var(--ink-2); font-size: 16.5px; line-height: 1.6; max-width: 46ch; }

/* whole-card click target: the title link stretches over the card */
.jfeature__title a, .jcard__title a {
  color: inherit; text-decoration: none;
  background: linear-gradient(currentColor 0 0) 0 100% / 0 1px no-repeat;
  transition: background-size .6s var(--ease);
}
.jfeature__title a::after, .jcard__title a::after { content: ""; position: absolute; inset: 0; z-index: 3; border-radius: inherit; }
.jfeature:hover .jfeature__title a, .jcard:hover .jcard__title a { background-size: 100% 1px; }
.jfeature__title a:focus-visible, .jcard__title a:focus-visible { outline: none; }
.jfeature:has(a:focus-visible), .jcard:has(a:focus-visible) { outline: 2px solid var(--moss); outline-offset: 4px; }
[data-glow="on"] .jfeature:has(a:focus-visible), [data-glow="on"] .jcard:has(a:focus-visible) { outline-color: var(--glow); }

.jcta { display: inline-flex; align-items: center; gap: 14px; margin-top: 8px; font-weight: 800; font-size: 15px; color: var(--ink); }
.jcta__dot {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: var(--moss); color: var(--moss-ink);
  transition: transform .5s var(--ease), background-color .3s var(--ease);
}
.jcta__dot .i { width: 18px; height: 18px; }
.jfeature:hover .jcta__dot { transform: rotate(-45deg) scale(1.08); background: var(--amanita); color: var(--amanita-ink); }
[data-glow="on"] .jfeature:hover .jcta__dot { background: var(--glow); color: var(--moss-ink); }

/* more stories */
.jmore { margin-top: clamp(56px, 8vw, 112px); }
.jmore__title { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.jmore__title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.jgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 4vw, 64px) clamp(20px, 3vw, 48px); align-items: start; }
.jgrid > .jcard:nth-child(even) { margin-top: clamp(0px, 7vw, 120px); }
.jcard { position: relative; display: flex; flex-direction: column; gap: 22px; }
.jcard__media { position: relative; aspect-ratio: 4 / 3; border-radius: var(--r-l); overflow: hidden; background: var(--chip); }
.jcard:hover .jcard__media img { transform: scale(1.07); }
.jcard__body { display: flex; flex-direction: column; gap: 12px; padding-right: 56px; }
.jcard__title { font-size: clamp(25px, 2.3vw, 34px); line-height: 1.1; letter-spacing: -.022em; }
.jcard__excerpt {
  color: var(--muted); font-size: 15.5px; line-height: 1.6; max-width: 52ch;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; overflow: hidden;
}
.jcard__go {
  position: absolute; right: 0; bottom: 0;
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line-2); color: var(--ink);
  transition: transform .5s var(--ease), background-color .3s var(--ease), border-color .3s var(--ease), color .3s var(--ease);
}
.jcard:hover .jcard__go { background: var(--moss); border-color: var(--moss); color: var(--moss-ink); transform: rotate(45deg); }
[data-glow="on"] .jcard:hover .jcard__go { background: var(--glow); border-color: var(--glow); box-shadow: 0 0 24px -4px var(--glow); }

/* keep exploring */
.jexplore { padding-top: clamp(64px, 8vw, 120px); }
.jexplore__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.jtile {
  position: relative; display: grid; grid-template-rows: auto auto 1fr auto; gap: 12px;
  min-height: 260px; padding: 28px; border-radius: var(--r-l);
  background: var(--panel); border: 1px solid var(--line);
  text-decoration: none; color: var(--ink);
  transition: transform .6s var(--ease), border-color .3s var(--ease), box-shadow .6s var(--ease), background-color .6s var(--ease);
}
.jtile:hover { transform: translateY(-6px); border-color: var(--line-2); box-shadow: 0 30px 60px -36px rgba(var(--shadow), .45); }
.jtile__icon { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--moss-tint); color: var(--moss); margin-bottom: 18px; transition: transform .6s var(--ease); }
.jtile:hover .jtile__icon { transform: rotate(-12deg) scale(1.06); }
.jtile__icon .i { width: 24px; height: 24px; }
.jtile__t { font-family: var(--font-display); font-size: clamp(21px, 1.8vw, 25px); line-height: 1.2; letter-spacing: -.015em; }
.jtile__go { justify-self: end; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--chip); transition: background-color .3s var(--ease), color .3s var(--ease), transform .5s var(--ease); }
.jtile__go .i { width: 17px; height: 17px; }
.jtile:hover .jtile__go { background: var(--moss); color: var(--moss-ink); transform: translateX(4px); }
.jtile--dark { background: var(--dark); color: var(--dark-ink); border-color: transparent; }
.jtile--dark .eyebrow { color: rgba(241, 235, 221, .6); }
.jtile--dark .jtile__icon { background: rgba(241, 235, 221, .1); color: var(--dark-ink); }
.jtile--dark .jtile__go { background: rgba(241, 235, 221, .12); }
.jtile--dark:hover .jtile__go { background: #ff7a6b; color: var(--dark); }
[data-glow="on"] .jtile:hover { border-color: color-mix(in srgb, var(--glow) 30%, transparent); box-shadow: 0 24px 60px -30px color-mix(in srgb, var(--glow) 35%, transparent); }
[data-glow="on"] .jtile--dark { background: var(--moss-tint); border-color: var(--line); }
[data-glow="on"] .jtile--dark:hover .jtile__go,
[data-glow="on"] .jtile:hover .jtile__go { background: var(--glow); color: var(--moss-ink); }
[data-glow="on"] .jtile__icon { color: var(--glow); }

/* ================================================================= POST */
.read-progress { position: fixed; inset: 0 0 auto; height: 3px; z-index: 70; pointer-events: none; }
.read-progress span {
  display: block; height: 100%; background: var(--accent);
  transform-origin: 0 50%; transform: scaleX(var(--p, 0));
}
[data-glow="on"] .read-progress span { box-shadow: 0 0 14px var(--glow), 0 0 4px var(--glow); }

.post-hero { padding-top: clamp(28px, 4vw, 56px); }
.post-crumbs ol { display: flex; flex-wrap: nowrap; align-items: center; gap: 8px; min-width: 0; }
.post-crumbs li { display: inline-flex; align-items: center; gap: 8px; flex: none; }
.post-crumbs li:last-child { flex: 0 1 auto; min-width: 0; }
.post-crumbs [aria-current] { display: block; max-width: 46ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.post-hero__head { max-width: 1040px; margin-top: clamp(28px, 4vw, 48px); }
.post-hero__title {
  margin-top: 20px;
  font-size: clamp(38px, 6vw, 88px); line-height: 1; letter-spacing: -.038em; font-weight: 380;
}
.post-hero__meta { margin-top: 26px; font-size: 14px; }
.post-hero__dek { margin-top: 22px; max-width: 62ch; }
/* Editorial 16:9 frame (the photos are square). The image is over-scaled by 7% so the ±3% parallax
   shift (journal.js) never exposes an edge. The reveal opens a clip and settles the scale, the
   image itself is never transparent, so it paints (LCP) on the first frame. */
.post-hero__media {
  --hero-r: var(--r-xl);
  position: relative; margin-top: clamp(36px, 5vw, 64px);
  aspect-ratio: 16 / 9; max-height: min(78svh, 760px); width: 100%;
  border-radius: var(--hero-r); overflow: hidden; background: var(--chip);
}
.post-hero__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: translate3d(0, var(--py, 0px), 0) scale(1.07);
  will-change: transform;
}
.js .post-hero__media { animation: hero-open 1.3s var(--ease) both; }
.js .post-hero__media img { animation: hero-settle 1.8s var(--ease) both; }
@keyframes hero-open { from { clip-path: inset(5% 3% round var(--hero-r)); } to { clip-path: inset(0 round var(--hero-r)); } }
@keyframes hero-settle { from { scale: 1.08; } to { scale: 1; } }

.post-layout {
  display: grid; grid-template-columns: 230px minmax(0, 68ch);
  justify-content: center; gap: clamp(40px, 6vw, 96px);
  padding-block: clamp(48px, 7vw, 104px) clamp(56px, 7vw, 96px);
}
.post-aside { position: sticky; top: calc(var(--header-h) + 28px); align-self: start; display: grid; gap: 32px; }
.post-toc .eyebrow { margin-bottom: 14px; }
.post-toc ol { border-left: 1px solid var(--line); }
.post-toc a {
  position: relative; display: block; padding: 7px 0 7px 16px;
  font-size: 13.5px; line-height: 1.4; font-weight: 600; color: var(--muted); text-decoration: none;
  transition: color .3s var(--ease);
}
.post-toc a::before {
  content: ""; position: absolute; left: -1px; top: 8px; bottom: 8px; width: 2px; border-radius: 2px;
  background: var(--accent); transform: scaleY(0); transition: transform .45s var(--ease);
}
.post-toc a:hover { color: var(--ink); }
.post-toc a[aria-current="true"] { color: var(--ink); }
.post-toc a[aria-current="true"]::before { transform: none; }
[data-glow="on"] .post-toc a[aria-current="true"]::before { box-shadow: 0 0 10px var(--glow); }
.post-aside__actions { display: grid; gap: 14px; justify-items: start; }
.post-back .i { transition: transform .35s var(--ease); }
.post-back:hover .i { transform: translateX(-3px); }
.post-copy {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px;
  border-radius: 999px; border: 1px solid var(--line-2);
  font-size: 13px; font-weight: 800; color: var(--ink-2);
  transition: border-color .25s var(--ease), background-color .25s var(--ease), color .25s var(--ease);
}
.post-copy .i { width: 16px; height: 16px; }
.post-copy:hover { border-color: var(--moss); color: var(--ink); }
.post-copy.is-done { background: var(--moss); border-color: var(--moss); color: var(--moss-ink); }

/* compact "In this story" bar, replaces the sidebar contents list at 1080px and below.
   Sticky inside the article body; sits below the header while it is shown, at the top once it hides. */
.post-tocbar { display: none; }
.post-body > .post-tocbar + * { margin-top: 0; }
.post-tocbar details { position: relative; }
.post-tocbar summary {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px;
  height: 52px; padding: 0 16px 0 20px; border-radius: 999px; cursor: pointer; list-style: none;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.3) blur(12px); backdrop-filter: saturate(1.3) blur(12px);
  border: 1px solid var(--line-2); box-shadow: 0 16px 36px -24px rgba(var(--shadow), .5);
  font-size: 14px; line-height: 1.2;
  transition: border-color .25s var(--ease), background-color .6s var(--ease);
}
.post-tocbar summary::-webkit-details-marker { display: none; }
.post-tocbar summary::marker { content: ""; }
.post-tocbar summary:hover { border-color: var(--moss); }
.post-tocbar summary:focus-visible { outline-offset: 3px; border-radius: 999px; }
.post-tocbar summary > .i { width: 18px; height: 18px; color: var(--muted); transition: transform .35s var(--ease); }
.post-tocbar details[open] summary > .i { transform: rotate(180deg); }
.post-tocbar__k { font-size: 10.5px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.post-tocbar__now { font-family: var(--font-display); font-size: 16px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-body .post-tocbar ol {
  position: absolute; left: 0; right: 0; top: calc(100% + 8px); z-index: 2;
  margin: 0; padding: 8px; border-radius: var(--r-l);
  background: var(--panel); border: 1px solid var(--line-2); box-shadow: 0 30px 60px -30px rgba(var(--shadow), .55);
  max-height: min(60svh, 420px); overflow: auto; overscroll-behavior: contain;
  animation: tocbar-in .35s var(--ease) both;
}
@keyframes tocbar-in { from { opacity: 0; transform: translateY(-6px); } }
.post-body .post-tocbar li { margin: 0; }
.post-body .post-tocbar a {
  display: block; padding: 11px 14px; border-radius: var(--r-s);
  font-size: 15px; line-height: 1.35; font-weight: 600; color: var(--ink-2); text-decoration: none;
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.post-body .post-tocbar a:hover { background: var(--chip); color: var(--ink); }
.post-body .post-tocbar a[aria-current="true"] { background: var(--moss-tint); color: var(--ink); box-shadow: inset 3px 0 0 var(--accent); }
[data-glow="on"] .post-tocbar summary { box-shadow: 0 0 0 1px color-mix(in srgb, var(--glow) 12%, transparent), 0 16px 40px -24px color-mix(in srgb, var(--glow) 40%, transparent); }

/* article body (on top of base .prose) */
.post-body { font-size: 18px; max-width: none; }
.post-body > p:first-of-type::first-letter {
  float: left; margin: .06em .12em 0 -.02em;
  font-family: var(--font-display); font-weight: 400; font-size: 4.6em; line-height: .78;
  font-variation-settings: "SOFT" 100, "WONK" 1; color: var(--accent);
}
.post-body h2 { letter-spacing: -.025em; }
.post-body h2:first-child { margin-top: 0; }
.post-body h3 { font-weight: 450; }
.post-body ul { list-style: none; padding-left: 0; }
.post-body ul li { position: relative; padding-left: 28px; }
.post-body ul li::before {
  content: ""; position: absolute; left: 4px; top: .72em; width: 9px; height: 9px; border-radius: 50%;
  border: 1.5px solid var(--accent);
}
[data-glow="on"] .post-body ul li::before { box-shadow: 0 0 8px color-mix(in srgb, var(--glow) 70%, transparent); }
.post-body hr {
  height: 10px; width: 60px; margin: 3em auto; background:
    radial-gradient(circle, var(--line-2) 2.5px, transparent 3px) 0 50% / 20px 10px repeat-x;
}
.post-body em { font-style: italic; }
.post-note {
  display: flex; gap: 12px; align-items: flex-start;
  margin-top: 3em !important; padding-top: 24px; border-top: 1px solid var(--line);
  font-size: 13px; line-height: 1.6; color: var(--muted);
}
.post-note .i { width: 18px; height: 18px; color: var(--moss); margin-top: 1px; }
[data-glow="on"] .post-note .i { color: var(--glow); }

/* related products */
.post-shop { background: var(--bg-2); transition: background-color .6s var(--ease); }
.post-shop__grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.6fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.post-shop__head { position: sticky; top: calc(var(--header-h) + 32px); display: grid; gap: 18px; justify-items: start; }
.post-shop__head .h2 { margin-top: 0; }
.post-shop__cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.post-shop__cards.is-single { grid-template-columns: minmax(0, 360px); }

/* previous / next */
.jpager { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(12px, 2vw, 24px); }
.jpager__link {
  display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: 20px; align-items: center;
  padding: 16px 22px 16px 16px; border-radius: var(--r-l);
  background: var(--panel); border: 1px solid var(--line);
  text-decoration: none; color: var(--ink);
  transition: border-color .3s var(--ease), transform .5s var(--ease), box-shadow .5s var(--ease), background-color .6s var(--ease);
}
.jpager__link--next { grid-template-columns: auto minmax(0, 1fr) 92px; padding: 16px 16px 16px 22px; text-align: right; }
.jpager__link--next .jpager__thumb { order: 3; }
.jpager__link--next .jpager__text { order: 2; }
.jpager__link--next .jpager__arrow { order: 1; }
.jpager__link:hover { border-color: var(--line-2); transform: translateY(-3px); box-shadow: 0 24px 48px -32px rgba(var(--shadow), .5); }
[data-glow="on"] .jpager__link:hover { border-color: color-mix(in srgb, var(--glow) 35%, transparent); box-shadow: 0 20px 50px -30px color-mix(in srgb, var(--glow) 40%, transparent); }
.jpager__thumb { position: relative; width: 92px; height: 92px; border-radius: var(--r); overflow: hidden; background: var(--chip); display: grid; place-items: center; color: var(--moss); }
.jpager__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.jpager__link:hover .jpager__thumb img { transform: scale(1.1); }
.jpager__thumb--icon .i { width: 30px; height: 30px; }
[data-glow="on"] .jpager__thumb--icon { color: var(--glow); }
.jpager__text { display: grid; gap: 6px; min-width: 0; }
.jpager__text .eyebrow { font-size: 10px; letter-spacing: .18em; }
.jpager__title { font-family: var(--font-display); font-size: clamp(18px, 1.6vw, 22px); line-height: 1.2; letter-spacing: -.012em; }
.jpager__arrow { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--chip); transition: transform .45s var(--ease), background-color .3s var(--ease), color .3s var(--ease); }
.jpager__arrow .i { width: 17px; height: 17px; }
.jpager__link--prev:hover .jpager__arrow { transform: translateX(-4px); background: var(--moss); color: var(--moss-ink); }
.jpager__link--next:hover .jpager__arrow { transform: translateX(4px); background: var(--moss); color: var(--moss-ink); }
.jpager__back { margin-top: 32px; text-align: center; }
.jpager__back .link-arrow .i { transition: transform .35s var(--ease); }
.jpager__back .link-arrow:hover .i { transform: translateX(-3px); }

/* shared-element morph between a story card and its post hero (cross-document view transitions).
   Card and hero have different aspect ratios, so the snapshots are clipped + cover-fitted
   inside the morphing frame instead of stretching. */
.jfeature__media, .jcard__media, .post-hero__media { view-transition-class: jmedia; }
::view-transition-group(*.jmedia) { animation-duration: .7s; animation-timing-function: cubic-bezier(.22, .8, .24, 1); }
::view-transition-image-pair(*.jmedia) { overflow: clip; border-radius: var(--r-l); }
::view-transition-old(*.jmedia), ::view-transition-new(*.jmedia) { height: 100%; object-fit: cover; }

/* ========================================================== RESPONSIVE */
@media (max-width: 1080px) {
  .post-layout { grid-template-columns: minmax(0, 1fr); max-width: calc(68ch + var(--gutter) * 2); gap: 0; }
  .post-aside { position: static; order: 2; margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); }
  .post-toc { display: none; }
  .post-tocbar {
    display: block; position: sticky; top: 12px; z-index: 30; margin-bottom: 40px;
    transition: top .45s var(--ease);
  }
  .site-header:not(.is-hidden) ~ main .post-tocbar { top: calc(var(--header-h) + 12px); }
  .post-body h2[id] { scroll-margin-top: 64px; } /* clear the sticky bar as well as the header */
  .post-aside__actions { grid-auto-flow: column; justify-content: space-between; align-items: center; }
}
@media (max-width: 960px) {
  .jhero__grid { grid-template-columns: minmax(0, 1fr); }
  .jfeature { grid-template-columns: minmax(0, 1fr); }
  .jfeature__media { aspect-ratio: 16 / 10; }
  .jexplore__grid { grid-template-columns: minmax(0, 1fr); }
  .jtile { min-height: 0; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto; column-gap: 18px; row-gap: 4px; align-items: center; }
  .jtile__icon { grid-row: 1 / 3; margin: 0; }
  .jtile__go { grid-column: 3; grid-row: 1 / 3; }
  .post-shop__grid { grid-template-columns: minmax(0, 1fr); }
  .post-shop__head { position: static; }
}
@media (max-width: 900px) {
  .jpager { grid-template-columns: minmax(0, 1fr); }
  .jpager__link, .jpager__link--next { grid-template-columns: 72px minmax(0, 1fr) auto; padding: 12px 16px 12px 12px; text-align: left; gap: 16px; }
  .jpager__link--next .jpager__thumb, .jpager__link--next .jpager__text, .jpager__link--next .jpager__arrow { order: 0; }
  .jpager__thumb { width: 72px; height: 72px; }
}
@media (max-width: 760px) {
  .jgrid { grid-template-columns: minmax(0, 1fr); }
  .jgrid > .jcard:nth-child(even) { margin-top: 0; }
  .jfeature { border-radius: var(--r-l); }
  .jfeature__media { aspect-ratio: 4 / 3; }
  .jfeature__body { gap: 16px; }
  .jcard__body { padding-right: 0; }
  .jcard__go { display: none; }
  .jtile { padding: 20px; }
  .jtile__icon { width: 44px; height: 44px; }
  .jtile__t { font-size: 18px; }
  .post-hero__media { --hero-r: var(--r-l); aspect-ratio: 4 / 3; }
  .post-crumbs [aria-current] { max-width: 22ch; }
  .post-body { font-size: 17px; }
}
@media (max-width: 560px) {
  .post-shop__cards { grid-template-columns: minmax(0, 1fr); }
  .post-aside__actions { grid-auto-flow: row; }
}

/* ======================================================= REDUCED MOTION */
@media (prefers-reduced-motion: reduce) {
  .post-hero__media, .post-hero__media img { animation: none !important; }
  .post-hero__media img { transform: scale(1.02) !important; }
  .jcursor { display: none; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}
