/* Jobs Foundation Ghost theme — brand tokens from JF site */

@font-face {
  font-family: 'Articulat CF';
  src: url('../fonts/ArticulatCF-Normal.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Articulat CF';
  src: url('../fonts/ArticulatCF-DemiBold.otf') format('opentype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Quincy CF';
  src: url('../fonts/QuincyCF-Regular.otf') format('opentype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Quincy CF';
  src: url('../fonts/QuincyCF-Bold.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --jf-pink: #e0007e;
  --jf-pink-hover: #b8006e; /* brand-guide */
  --jf-navy: #3d487e;
  --jf-navy-dark: #2f3868;
  --jf-navy-deep: #001965;
  --jf-text: #111111;
  --jf-heading: #1a1a2e;
  --jf-muted: #666666;
  --jf-bg: #f8f8f8;
  --jf-white: #ffffff;
  --jf-line: #ebebeb;
  --jf-border: #e5e5e5;
  --jf-max: 1100px;
  /* Edge gap only when the viewport is narrower than the content box */
  --jf-gutter: 1rem;
  --jf-font-sans: 'Articulat CF', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --jf-font-serif: 'Quincy CF', Georgia, 'Times New Roman', serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--jf-white);
  height: 100%;
}

body.jf-body {
  margin: 0;
  font-family: var(--jf-font-sans);
  color: var(--jf-text);
  background: var(--jf-white);
  line-height: 1.55;
  display: flex !important;
  flex-direction: column !important;
  min-height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--jf-pink);
}

a:hover {
  color: var(--jf-navy);
}

.jf-skip {
  position: absolute;
  left: -9999px;
}
.jf-skip:focus {
  left: 16px;
  top: 16px;
  z-index: 100;
  background: var(--jf-white);
  padding: 8px 12px;
}

/* Centred 1100px content box — no extra 40px inset inside the box */
.jf-wrap {
  width: 100%;
  max-width: min(var(--jf-max), calc(100% - (2 * var(--jf-gutter))));
  margin-inline: auto;
  padding-inline: 0;
  box-sizing: border-box;
}

.jf-eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--jf-pink);
}

/* Matches site .sec-label — pink Articulat caps (e.g. “Latest news” on /news) */
.jf-section-title {
  margin: 0 0 20px;
  font-family: var(--jf-font-sans);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--jf-pink);
}

/* Non-home: solid header sits in normal flow above content */
.post-template .jf-header,
.page-template .jf-header,
.tag-template .jf-header,
.author-template .jf-header,
.error-template .jf-header {
  position: relative;
  background: var(--jf-white);
  border-bottom: 0.5px solid var(--jf-line);
}

/* Homepage: nav sits on the hero photo (same as site /campaigns) */
.home-template .jf-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: transparent;
  border-bottom: none;
}

.home-template .jf-nav__link {
  color: rgba(255, 255, 255, 0.92);
}

.home-template .jf-nav__link:hover,
.home-template .jf-nav__link.is-current {
  color: #fff;
}

.jf-header__inner {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 14px 24px;
  min-height: 64px;
  height: 64px;
  padding-block: 0;
}

@media (max-width: 900px) {
  .jf-header__inner {
    flex-wrap: wrap;
    height: auto;
    min-height: 64px;
    padding-block: 0.75rem;
    gap: 12px;
  }

  .jf-nav {
    display: none;
  }

  .jf-logo-horizontal {
    font-size: 1.15rem;
  }
}

@media (max-width: 480px) {
  .jf-logo-horizontal__foundation {
    display: none;
  }

  .jf-hero__content {
    padding-top: 4.5rem;
  }

  .jf-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .jf-hero__actions .jf-btn {
    width: 100%;
  }
}

.jf-logo {
  text-decoration: none;
  line-height: 1;
}

.jf-logo--pink,
.jf-logo--pink:hover,
.jf-logo--pink:focus-visible {
  color: var(--jf-pink);
  text-decoration: none;
}

/* Same lockup as Payload site (pink glyph + Articulat wordmark) */
.jf-logo-horizontal {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  color: inherit;
  line-height: 1;
  font-size: 1.35rem;
}

.jf-logo-horizontal__mark {
  display: block;
  height: 0.92em;
  width: auto;
  flex-shrink: 0;
}

.jf-logo-horizontal__wordmark {
  font-family: var(--jf-font-sans);
  font-size: 1em;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  font-synthesis: none;
}

.jf-logo-horizontal__jobs {
  font-weight: 600;
}

.jf-logo-horizontal__foundation {
  font-weight: 400;
}

.jf-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  flex: 1;
  justify-content: center;
}

.jf-nav__link {
  color: var(--jf-navy);
  text-decoration: none;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.01em;
  padding: 0 14px;
  height: 64px;
  display: inline-flex;
  align-items: center;
}

.jf-nav__link:hover,
.jf-nav__link.is-current {
  color: var(--jf-pink);
}

/* Buttons — brand guide CTA pills */
.jf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 28px;
  font-size: 13.5px;
  font-weight: 600;
  font-family: var(--jf-font-sans);
  text-decoration: none;
  border-radius: 50px;
  border: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.jf-header .jf-btn {
  padding: 0.5rem 1.125rem;
  font-size: 0.75rem;
  font-weight: 500;
}

.jf-btn--pink {
  background: var(--jf-pink);
  color: var(--jf-white) !important;
}

.jf-btn--pink:hover,
.jf-btn--pink:focus-visible {
  background: var(--jf-pink-hover);
  color: var(--jf-white) !important;
  text-decoration: none;
}

.jf-btn--ghost {
  background: transparent;
  color: var(--jf-navy) !important;
  border: 2px solid var(--jf-navy);
}

.jf-btn--ghost:hover,
.jf-btn--ghost:focus-visible {
  color: var(--jf-pink) !important;
  border-color: var(--jf-pink);
  text-decoration: none;
}

.jf-logo__img {
  height: 40px;
  width: auto;
}

.jf-footer__logo,
.jf-footer__logo:hover,
.jf-footer__logo:focus-visible,
.jf-footer a.jf-footer__logo {
  display: inline-flex;
  color: #fff !important;
  margin: 0 0 12px;
  font-size: 1.0625rem;
  text-decoration: none;
}

.jf-hero__title {
  margin: 0 0 8px;
  font-family: var(--jf-font-sans);
  font-weight: 600;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  line-height: 1.2;
  color: #fff;
}

.jf-hero__tagline {
  margin: 0 0 12px;
  font-family: var(--jf-font-serif);
  font-style: italic;
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  color: rgba(255, 255, 255, 0.9);
  font-weight: 400;
}

.jf-hero {
  position: relative;
  overflow: hidden;
  padding: 0;
  border-bottom: none;
  min-height: 12.5rem;
  color: #fff;
}

/* Same treatment as staging /campaigns page-hero--photo */
.jf-hero--photo::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--hero-photo-url);
  background-size: cover;
  background-position: center;
}

.jf-hero--photo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgb(61 72 126 / 78%);
}

.jf-hero__content {
  position: relative;
  z-index: 1;
  padding: 5.5rem 0 2.5rem;
}

.jf-hero__desc {
  margin: 0 0 20px;
  max-width: 37.5rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.95rem;
  line-height: 1.7;
}

.jf-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0;
}

/* Feed — match site /news list (no boxed card outlines) */
.jf-feed,
.jf-archive {
  padding: 40px 0 56px;
  background: var(--jf-white);
}

.jf-archive__header {
  margin-bottom: 28px;
}

.jf-post-list {
  display: flex;
  flex-direction: column;
}

.jf-news-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1.5rem;
  padding: 1.5rem 0;
  border-bottom: 0.5px solid var(--jf-line);
  align-items: start;
}

.jf-news-item:last-child {
  border-bottom: none;
}

.jf-news-item__image {
  display: block;
  width: 160px;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 4px;
  background: #f2f4f9;
}

.jf-news-item__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.jf-news-date {
  text-align: center;
  padding-top: 3px;
}

.jf-news-date__day {
  font-family: var(--jf-font-sans);
  font-size: 28px;
  font-weight: 700;
  color: var(--jf-navy);
  line-height: 1;
}

.jf-news-date__month {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--jf-pink);
  font-weight: 700;
}

.jf-news-date__year {
  font-size: 11px;
  color: #bbb;
}

.jf-news-type {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--jf-pink);
  margin-bottom: 6px;
  font-weight: 700;
}

.jf-news-item__title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--jf-heading);
}

.jf-news-item__title a {
  color: inherit;
  text-decoration: none;
}

.jf-news-item__title a:hover {
  color: var(--jf-pink);
}

.jf-news-item__excerpt {
  margin: 0 0 8px;
  font-size: 12.5px;
  color: var(--jf-muted);
  line-height: 1.65;
}

.jf-news-item__link {
  font-family: var(--jf-font-sans);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--jf-navy);
  text-decoration: none;
  display: inline-block;
}

.jf-news-item__link:hover {
  color: var(--jf-pink);
}

.jf-empty {
  color: var(--jf-muted);
  font-size: 14px;
  padding: 1.5rem 0;
}

/* Article / post — single centred column (image + body same width, as before) */
.jf-article {
  padding: 2.5rem 0 4rem;
  width: 100%;
}

.jf-article__inner {
  width: 100%;
  max-width: min(720px, calc(100% - (2 * var(--jf-gutter))));
  margin-inline: auto;
  box-sizing: border-box;
}

.jf-article__header {
  margin-bottom: 1.5rem;
}

.jf-article__title {
  margin: 0 0 12px;
  font-family: var(--jf-font-sans);
  font-size: clamp(1.6rem, 3.5vw, 2.25rem);
  font-weight: 600;
  color: var(--jf-heading);
  line-height: 1.2;
}

.jf-article__meta {
  margin: 0 0 1.25rem;
  color: var(--jf-muted);
  font-size: 0.875rem;
}

.jf-article__figure {
  margin: 0 0 1.5rem;
}

.jf-article__figure img {
  width: 100%;
  display: block;
  border-radius: 4px;
  background: #f2f4f9;
}

.jf-content {
  font-family: var(--jf-font-serif);
  font-size: 1.125rem; /* 18px brand body */
  line-height: 1.5;
  color: var(--jf-text);
}

.jf-content > *:first-child {
  margin-top: 0;
}

.jf-content p,
.jf-content ul,
.jf-content ol {
  margin: 0 0 1.125rem;
}

.jf-content h2,
.jf-content h3,
.jf-content h4 {
  font-family: var(--jf-font-sans);
  color: var(--jf-navy);
  margin-top: 1.6em;
  margin-bottom: 0.6em;
  line-height: 1.25;
}

.jf-content a {
  color: var(--jf-pink);
}

.jf-content img {
  margin: 1.25em 0;
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

.jf-content blockquote {
  font-family: var(--jf-font-sans);
  font-style: italic;
  font-weight: 400;
  color: var(--jf-navy);
  border-left: 3px solid var(--jf-pink);
  padding: 0 0 0 1.25rem;
  margin: 1.25rem 0;
}

/* Ghost card / Koenig — keep inside the post column on mobile */
.jf-content .kg-width-wide,
.jf-content .kg-width-full {
  position: relative;
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  transform: none;
}

@media (min-width: 900px) {
  .jf-content .kg-width-wide {
    width: min(100vw - (2 * var(--jf-gutter)), 960px);
    max-width: none;
    margin-left: 50%;
    transform: translateX(-50%);
  }

  .jf-content .kg-width-full {
    width: 100vw;
    max-width: none;
    margin-left: 50%;
    transform: translateX(-50%);
  }
}

.jf-content .kg-width-full img,
.jf-content .kg-width-wide img {
  width: 100%;
}

.jf-article__back {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 0.5px solid var(--jf-line);
  font-size: 0.875rem;
}

.jf-article__back a {
  color: var(--jf-navy);
  text-decoration: none;
  font-weight: 600;
}

.jf-article__back a:hover {
  color: var(--jf-pink);
}

.jf-article__back-sep {
  margin: 0 0.4rem;
  color: var(--jf-muted);
}

@media (max-width: 768px) {
  .jf-article {
    padding: 1.5rem 0 3rem;
  }

  .jf-article__title {
    font-size: 1.5rem;
  }

  .jf-content {
    font-size: 1.0625rem;
  }
}

/* Footer — match site .home-site-footer; always pin to bottom of viewport */
.jf-footer {
  background: var(--jf-navy-dark);
  color: #fff;
  padding: 2.25rem 0 1.25rem;
  width: 100%;
  max-width: none;
  /* Never let Ghost stretch the footer into a tall flex column (causes mobile mid-gap) */
  display: block !important;
  flex: 0 0 auto !important;
  flex-grow: 0 !important;
  flex-shrink: 0 !important;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  margin-top: auto !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  text-align: left;
  justify-content: flex-start !important;
  align-items: stretch !important;
  gap: 0 !important;
}

.jf-footer a {
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
}

.jf-footer a:hover {
  color: var(--jf-pink);
}

.jf-footer__top,
.jf-footer__bottom {
  width: 100%;
  max-width: min(var(--jf-max), calc(100% - (2 * var(--jf-gutter))));
  margin-inline: auto;
  padding-inline: 0;
  box-sizing: border-box;
}

.jf-footer__top {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: flex-start;
  align-content: flex-start;
  gap: 2rem;
  padding-top: 0;
  padding-bottom: 1.75rem;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 1rem;
  flex-grow: 0 !important;
  flex-shrink: 0 !important;
  min-height: 0 !important;
  height: auto !important;
}

.jf-footer__brand {
  flex: 0 1 36rem;
  max-width: 36rem;
  margin: 0;
  padding: 0;
  text-align: left;
}

.jf-footer__col--social {
  flex: 0 0 auto;
  margin-left: auto;
  margin-right: 0;
  text-align: left;
}

.jf-footer__desc {
  margin: 0;
  max-width: 36rem;
  font-size: 12px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.4);
  text-align: left;
}

.jf-footer__desc p {
  margin: 0;
}

.jf-footer__desc p + p {
  margin-top: 0.85em;
}

.jf-footer__col h4 {
  font-family: var(--jf-font-sans);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
  margin: 0 0 12px;
  font-weight: 400;
}

.jf-footer__col a {
  display: block;
  font-size: 12px;
  margin-bottom: 7px;
}

.jf-footer__bottom {
  display: block;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.25);
  text-align: left;
}

.jf-footer__ghost a {
  color: rgba(255, 255, 255, 0.5);
}

/* Mobile: block stack — no flex space-between gap between brand and socials */
@media (max-width: 768px) {
  .jf-footer {
    padding-top: 1.75rem;
    padding-bottom: 1.25rem;
  }

  .jf-footer__top {
    display: block !important;
    height: auto !important;
    min-height: 0 !important;
    padding-bottom: 1.25rem;
    margin-bottom: 1rem;
  }

  .jf-footer__brand {
    max-width: none;
    width: 100%;
    margin: 0 0 1.5rem;
  }

  .jf-footer__col--social {
    display: block;
    width: 100%;
    margin: 0;
  }

  .jf-footer__bottom {
    display: block;
  }

  .jf-news-item {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .jf-news-item__image {
    width: 100%;
  }

  .jf-news-date {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    text-align: left;
    padding-top: 0;
  }

  .jf-news-date__day {
    font-size: 22px;
  }
}

/* Pagination */
.jf-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}

.jf-pagination__status {
  color: var(--jf-muted);
  font-size: 0.9rem;
}

.jf-error {
  padding: 80px 0;
  text-align: center;
}

.jf-main {
  flex: 1 1 auto !important;
  min-height: 0;
  width: 100%;
}
