/* Journal listing. Prefix jn- so homepage / treatment / about stay untouched. */

.jn-main {
  width: 100%;
  padding: 128px 0 calc(var(--promo-h, 100px) + 48px);
}

.jn-container {
  width: min(1440px, 100%);
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: 48px;
}

.landing p.jn-kicker,
.jn-kicker {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 20px;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
}

.jn-title,
.landing h1.jn-title {
  margin: 0;
  max-width: 920px;
  color: var(--ink);
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 1.06;
  overflow-wrap: break-word;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
}

.jn-lede,
.landing .jn-lede {
  margin: 28px 0 0;
  max-width: 540px;
  color: var(--muted);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.45;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
}

.jn-intro {
  margin-bottom: 56px;
}

.jn-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.jn-filter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1;
  white-space: nowrap;
  transition:
    background-color 0.3s cubic-bezier(0.44, 0, 0.56, 1),
    border-color 0.3s cubic-bezier(0.44, 0, 0.56, 1),
    color 0.3s cubic-bezier(0.44, 0, 0.56, 1);
}

.jn-filter.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
}

.landing p.jn-count,
.jn-count {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
}

.jn-list {
  border-top: 1px solid var(--line);
}

.jn-row {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  color: inherit;
}

.jn-row__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.45;
}

.jn-row__title {
  color: var(--ink);
  font-size: clamp(24px, 2.6vw, 36px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.2;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
  text-decoration: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition: text-decoration-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

.jn-row__excerpt {
  max-width: 640px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.5;
}

.jn-pager {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  margin-top: 32px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.45;
}

.jn-pager__status {
  justify-self: center;
}

.jn-pager__link {
  width: max-content;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition: text-decoration-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

.jn-pager__link:not(.jn-pager__link--next) {
  justify-self: start;
}

.jn-pager__link.jn-pager__link--next {
  justify-self: end;
}

.jn-pager__link.is-disabled {
  color: var(--grey);
  pointer-events: none;
}

.jn-page [data-inview] {
  transition-delay: var(--d, 0s);
}

@media (hover: hover) and (pointer: fine) {
  .jn-filter:hover {
    background-color: var(--sage);
    border-color: var(--sage);
  }

  .jn-filter.is-active:hover {
    background-color: var(--ink);
    border-color: var(--ink);
    color: var(--white);
  }

  .jn-row.is-inview:hover .jn-row__title {
    text-decoration-color: currentColor;
  }

  .jn-pager__link:hover {
    text-decoration-color: currentColor;
  }
}

@media (max-width: 1199.98px) {
  .jn-main {
    padding-top: 120px;
  }

  .jn-title,
  .landing h1.jn-title {
    font-size: clamp(40px, 5.4vw, 64px);
  }
}

@media (max-width: 991.98px) {
  .jn-main {
    padding-top: 112px;
  }

  .jn-container {
    padding-inline: 24px;
  }

  .jn-title,
  .landing h1.jn-title {
    max-width: none;
    font-size: clamp(40px, 6.4vw, 56px);
  }

  .jn-lede,
  .landing .jn-lede {
    max-width: none;
  }

  .jn-row__excerpt {
    max-width: none;
  }

  .jn-intro {
    margin-bottom: 40px;
  }
}

@media (max-width: 767.98px) {
  .jn-main {
    padding: 104px 0 calc(var(--promo-h, 100px) + 40px);
  }

  .landing.jn-page [data-inview] {
    transform: translateY(16px);
  }

  .landing.jn-page [data-inview].is-inview {
    transform: none;
  }

  .jn-title,
  .landing h1.jn-title {
    max-width: none;
    font-size: 32px;
    line-height: 1.1;
  }

  .jn-lede,
  .landing .jn-lede {
    margin-top: 20px;
    font-size: 16px;
    line-height: 1.45;
  }

  .jn-intro {
    margin-bottom: 32px;
  }

  .jn-row {
    padding: 24px 0;
    gap: 10px;
  }

  .jn-row__title {
    font-size: 24px;
  }

  .jn-row__excerpt {
    max-width: none;
    font-size: 15px;
  }

  .jn-pager {
    margin-top: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .jn-filter,
  .jn-row__title,
  .jn-pager__link,
  .jn-post__related-card,
  .jn-kicker a,
  .jn-post__body a {
    transition: none;
  }
}

/* Single post template — reuse these classes when posts go dynamic. */

.jn-post {
  width: 100%;
  max-width: 100%;
}

.jn-post__hero {
  margin-bottom: 32px;
}

.jn-kicker a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: currentColor;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition:
    color 0.35s cubic-bezier(0.44, 0, 0.56, 1),
    text-decoration-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

@media (hover: hover) and (pointer: fine) {
  .jn-kicker a:hover {
    color: var(--ink);
    text-decoration: none;
  }
}

.jn-title--post,
.landing h1.jn-title--post {
  max-width: none;
  font-size: clamp(36px, 4.8vw, 64px);
  line-height: 1.08;
}

.landing p.jn-post__byline,
.jn-post__byline {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.45;
}

.jn-post__media {
  overflow: hidden;
  margin: 0 0 40px;
  border-radius: 8px;
}

.jn-post__media img {
  display: block;
  width: 100%;
  height: auto;
}

.jn-post__body {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 16px;
  min-width: 0;
}

.landing .jn-post__body > p:first-child,
.jn-post__body > p:first-child {
  color: var(--ink);
  font-size: 20px;
  letter-spacing: -0.03em;
  line-height: 1.45;
}

.jn-post__body p,
.landing .jn-post__body p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.55;
}

.jn-post__body h2,
.jn-post__body h3,
.jn-post__body h4,
.jn-post__body h5,
.jn-post__body h6,
.landing .jn-post__body h2,
.landing .jn-post__body h3,
.landing .jn-post__body h4,
.landing .jn-post__body h5,
.landing .jn-post__body h6 {
  margin: 28px 0 0;
  color: var(--ink);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.2;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
}

.landing .jn-post__body h2,
.jn-post__body h2 {
  font-size: clamp(24px, 3vw, 32px);
}

.landing .jn-post__body h3,
.jn-post__body h3 {
  font-size: 22px;
}

.landing .jn-post__body h4,
.jn-post__body h4 {
  font-size: 18px;
}

.landing .jn-post__body h5,
.jn-post__body h5 {
  font-size: 16px;
}

.landing .jn-post__body h6,
.jn-post__body h6 {
  font-size: 14px;
  letter-spacing: -0.02em;
}

.jn-post__body a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: currentColor;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition:
    color 0.35s cubic-bezier(0.44, 0, 0.56, 1),
    text-decoration-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

@media (hover: hover) and (pointer: fine) {
  .jn-post__body a:hover {
    color: var(--ink);
    text-decoration: none;
  }
}

.jn-post__body ul,
.jn-post__body ol {
  margin: 0;
  padding: 0 0 0 20px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.55;
}

.jn-post__body li + li {
  margin-top: 6px;
}

.jn-post__body li ul,
.jn-post__body li ol {
  margin-top: 6px;
}

.jn-post__body blockquote {
  margin: 0;
  padding: 4px 0 4px 16px;
  border-left: 2px solid var(--sage);
  color: var(--ink);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.45;
}

.jn-post__body hr {
  width: 100%;
  margin: 8px 0;
  border: 0;
  border-top: 1px solid var(--line);
}

.jn-post__body em,
.jn-post__body i {
  font-style: italic;
}

.jn-post__body small {
  font-size: 0.85em;
}

.jn-post__body sub,
.jn-post__body sup {
  font-size: 0.72em;
  line-height: 0;
}

.jn-post__body mark {
  padding: 0 0.2em;
  background: var(--sage);
  color: var(--ink);
}

.jn-post__body s,
.jn-post__body del {
  color: var(--grey);
  text-decoration-thickness: 1px;
}

.jn-post__body ins {
  text-decoration: none;
  background: var(--sage);
}

.jn-post__body abbr {
  text-decoration: underline dotted;
  text-underline-offset: 3px;
  cursor: help;
}

.jn-post__body cite,
.jn-post__body q {
  color: var(--ink);
  font-style: italic;
}

.jn-post__body code,
.jn-post__body kbd,
.jn-post__body samp {
  padding: 0.12em 0.4em;
  border-radius: 4px;
  background: var(--white);
  color: var(--ink);
  font-size: 0.88em;
  font-weight: 500;
  letter-spacing: 0;
}

.jn-post__body pre {
  margin: 0;
  padding: 16px 18px;
  overflow-x: auto;
  border-radius: 8px;
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
}

.jn-post__body pre code {
  padding: 0;
  background: transparent;
  font-size: inherit;
}

.jn-post__body dl {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(8rem, 12rem) minmax(0, 1fr);
  gap: 8px 24px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.55;
}

.jn-post__body dt {
  color: var(--ink);
}

.jn-post__body dd {
  margin: 0;
}

.jn-post__body blockquote p,
.landing .jn-post__body blockquote p {
  color: var(--ink);
  font-size: inherit;
}

.jn-post__body blockquote cite,
.jn-post__body blockquote footer {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  font-style: normal;
}

.jn-post__body details {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.jn-post__body summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 500;
}

.jn-post__body details p,
.landing .jn-post__body details p {
  margin-top: 10px;
}

.jn-post__body iframe,
.jn-post__body video,
.jn-post__body audio {
  display: block;
  width: 100%;
  max-width: 100%;
  border: 0;
  border-radius: 8px;
  background: var(--sage);
}

.jn-post__body iframe,
.jn-post__body video {
  aspect-ratio: 16 / 9;
  height: auto;
}

.jn-post__body img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.jn-post__body figure {
  width: 100%;
  margin: 0;
  overflow-x: auto;
}

.jn-post__body table {
  width: 100%;
  min-width: 520px;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.jn-post__body caption {
  caption-side: bottom;
  padding: 10px 16px 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.45;
  text-align: left;
}

.jn-post__body th,
.jn-post__body td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  overflow-wrap: break-word;
}

.jn-post__body th:last-child,
.jn-post__body td:last-child {
  border-right: 0;
}

.jn-post__body tbody tr:last-child td,
.jn-post__body tbody tr:last-child th {
  border-bottom: 0;
}

.jn-post__body thead tr:first-child > *:first-child,
.jn-post__body table:not(:has(thead)) tbody tr:first-child > *:first-child {
  border-top-left-radius: 8px;
}

.jn-post__body thead tr:first-child > *:last-child,
.jn-post__body table:not(:has(thead)) tbody tr:first-child > *:last-child {
  border-top-right-radius: 8px;
}

.jn-post__body tbody:last-child tr:last-child > *:first-child,
.jn-post__body tfoot:last-child tr:last-child > *:first-child {
  border-bottom-left-radius: 8px;
}

.jn-post__body tbody:last-child tr:last-child > *:last-child,
.jn-post__body tfoot:last-child tr:last-child > *:last-child {
  border-bottom-right-radius: 8px;
}

.jn-post__body th {
  background: var(--sage);
  color: var(--ink);
}

.jn-post__body td {
  background: var(--white);
  color: var(--muted);
}

.jn-post__body strong,
.jn-post__body td strong {
  color: var(--ink);
  font-weight: 500;
}

.jn-post__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 40px;
  margin-top: 48px;
  padding: 36px 40px;
  border-radius: 8px;
  background: var(--sage);
}

.jn-post__cta-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
  max-width: 34rem;
}

.landing p.jn-post__cta-kicker,
.jn-post__cta-kicker {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.45;
  opacity: 0.7;
}

.landing p.jn-post__cta-lede,
.jn-post__cta-lede {
  margin: 0;
  color: var(--ink);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.2;
  font-feature-settings: "calt" 0, "salt", "ss01", "ss05", "ss06", "ss07", "ss08";
}

.landing p.jn-post__cta-note,
.jn-post__cta-note {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.45;
}

.jn-post__cta-note s {
  color: var(--muted);
  text-decoration-thickness: 1px;
}

.jn-post__cta .landing-cta {
  flex: none;
  height: 48px;
  min-height: 48px;
  padding: 12px 20px;
  background: var(--ink);
}

.jn-post__cta .landing-cta__label {
  color: var(--cream);
}

.jn-post__cta .landing-cta.is-hover .landing-cta__label,
.jn-post__cta .landing-cta:hover .landing-cta__label,
.jn-post__cta .landing-cta:focus-visible .landing-cta__label {
  color: var(--ink);
}

.jn-post__cta .landing-cta__fill {
  background: var(--cream);
}

.jn-post__refs,
.jn-post__related {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}

.jn-post__subhead,
.landing h2.jn-post__subhead {
  margin: 0 0 16px;
  color: var(--ink);
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.3;
}

.jn-post__refs ol {
  margin: 0;
  padding: 0 0 0 20px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.55;
}

.jn-post__refs li + li {
  margin-top: 6px;
}

.landing p.jn-post__disclaimer,
.jn-post__disclaimer {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
}

.jn-post__related-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.jn-post__related-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: inherit;
  transition:
    opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.8s cubic-bezier(0.4, 0, 0.2, 1),
    background-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

.landing .jn-post__related-card[data-inview] {
  transition:
    opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.8s cubic-bezier(0.4, 0, 0.2, 1),
    background-color 0.35s cubic-bezier(0.44, 0, 0.56, 1);
}

.jn-post__related-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}

.jn-post__related-card strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.35;
}

@media (hover: hover) and (pointer: fine) {
  .jn-post__related-card:hover {
    background-color: var(--sage);
  }
}

@media (max-width: 991.98px) {
  .jn-title--post,
  .landing h1.jn-title--post {
    font-size: clamp(32px, 5.4vw, 48px);
  }

  .jn-post__media {
    margin-bottom: 32px;
  }

  .landing .jn-post__body h2,
  .jn-post__body h2 {
    font-size: 28px;
  }

  .landing .jn-post__body h3,
  .jn-post__body h3 {
    font-size: 20px;
  }

  .jn-post__cta {
    padding: 28px 24px;
    gap: 20px;
  }

  .jn-post__refs,
  .jn-post__related {
    margin-top: 40px;
    padding-top: 28px;
  }

  .jn-post__related-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767.98px) {
  .jn-post__hero {
    margin-bottom: 24px;
  }

  .jn-title--post,
  .landing h1.jn-title--post {
    font-size: 32px;
    line-height: 1.12;
  }

  .jn-post__media {
    margin-bottom: 24px;
  }

  .jn-post__body {
    gap: 12px;
  }

  .jn-post__body > p:first-child,
  .landing .jn-post__body > p:first-child {
    font-size: 18px;
  }

  .jn-post__body p,
  .landing .jn-post__body p,
  .jn-post__body ul,
  .jn-post__body ol {
    font-size: 16px;
  }

  .jn-post__body h2,
  .landing .jn-post__body h2 {
    margin-top: 20px;
    font-size: 24px;
  }

  .jn-post__body h3,
  .landing .jn-post__body h3 {
    font-size: 18px;
  }

  .jn-post__body dl {
    grid-template-columns: 1fr;
    gap: 4px 0;
  }

  .jn-post__body dt + dd {
    margin-bottom: 10px;
  }

  .jn-post__body table {
    min-width: 0;
  }

  .jn-post__body th,
  .jn-post__body td {
    padding: 10px 12px;
    font-size: 13px;
  }

  .jn-post__body th:first-child,
  .jn-post__body td:first-child {
    width: 36%;
    min-width: 6.75rem;
  }

  .jn-post__body caption {
    padding: 8px 12px 10px;
    font-size: 12px;
  }

  .jn-post__cta {
    margin-top: 32px;
    padding: 24px 20px;
    gap: 16px;
  }

  .landing p.jn-post__cta-lede,
  .jn-post__cta-lede {
    font-size: 22px;
  }

  .jn-post__refs,
  .jn-post__related {
    margin-top: 32px;
    padding-top: 24px;
  }

  .jn-post__subhead,
  .landing h2.jn-post__subhead {
    font-size: 24px;
  }

  .jn-post__related-list {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .jn-post__related-card {
    padding: 16px 18px;
  }
}
