/* ==========================================================================
   Signal & Forge — Ghost Theme
   Ported from src/styles/global.css and src/styles/blog.css on the main site.
   ========================================================================== */

/* ---------- Custom Properties ---------- */
:root {
  --bg-primary: #0A0A0A;
  --bg-secondary: #0F0F0F;
  --bg-tertiary: #161616;
  --bg-card: #1A1A1A;
  --bg-card-hover: #1E1E1E;

  --text-primary: #F5F2EB;
  --text-secondary: #999999;
  --text-muted: #8C8C8C; /* 4.5:1+ on every dark background (WCAG 1.4.3) */

  --charcoal: #212121;
  --orange: #EF8114;
  --orange-light: #F49A3A;
  --orange-dark: #D06F0E;
  --orange-glow: rgba(239, 129, 20, 0.12);

  /* Ghost's Typography setting (Design → Brand) overrides these when set */
  --font-display: var(--gh-font-heading, 'Bebas Neue'), 'Arial Narrow', sans-serif;
  --font-body: var(--gh-font-body, 'Inter'), -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --nav-height: 80px;
  --container-max: 1280px;
  --container-padding: 24px;
  --content-width: 720px;
  --wide-width: 1040px;

  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  /* Keep focused/anchored content out from under the fixed nav (WCAG 2.4.11) */
  scroll-padding-top: calc(var(--nav-height) + 16px);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  overflow-x: hidden;
}

/* ---------- Accessibility ---------- */
:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 10000;
  padding: 12px 20px;
  background: var(--orange);
  color: var(--bg-primary);
  font-weight: 600;
  text-decoration: none;
  border-radius: 2px;
  transform: translateY(-200%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

main:focus {
  outline: none;
}

::selection {
  background-color: var(--orange);
  color: var(--bg-primary);
}

::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--orange-dark);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--orange);
}

img {
  max-width: 100%;
  display: block;
}

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

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
  color: inherit;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

/* ---------- Scroll Progress ---------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: linear-gradient(90deg, var(--orange-dark), var(--orange), var(--orange-light));
  z-index: 1001;
}

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 100;
  transition: background-color 0.4s ease, backdrop-filter 0.4s ease;
}

.nav--scrolled {
  background-color: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav__container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.06em;
  display: flex;
  transition: opacity 0.3s ease;
}

.nav__logo:hover {
  opacity: 0.8;
}

.nav__logo-signal {
  color: var(--text-primary);
}

.nav__logo-forge {
  color: var(--orange);
}

.nav__links {
  display: flex;
  gap: 40px;
}

.nav__link {
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  transition: color 0.3s ease;
  position: relative;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--orange);
  transition: width 0.3s var(--ease-out-expo);
}

.nav__link:hover,
.nav__link--active {
  color: var(--text-primary);
}

.nav__link:hover::after,
.nav__link--active::after {
  width: 100%;
}

.nav__cta {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bg-primary);
  background-color: var(--orange);
  padding: 10px 24px;
  border-radius: 2px;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.nav__cta:hover {
  background-color: var(--orange-light);
  transform: translateY(-1px);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
  z-index: 101;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--text-primary);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav__toggle--active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__toggle--active span:nth-child(2) {
  opacity: 0;
}

.nav__toggle--active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Mobile Menu ---------- */
.mobile-menu {
  position: fixed;
  inset: 0;
  background-color: rgba(10, 10, 10, 0.98);
  z-index: 99;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.mobile-menu--open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.mobile-menu__link {
  font-family: var(--font-display);
  font-size: 2.5rem;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.mobile-menu__link:hover,
.mobile-menu__cta {
  color: var(--orange);
}

/* ---------- Blog Listing ---------- */
.blog-listing {
  padding: calc(var(--nav-height) + 80px) 0 120px;
  background-color: var(--bg-primary);
  min-height: 100vh;
}

.blog-listing__header {
  margin-bottom: 64px;
}

.blog-listing__eyebrow {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 16px;
}

.blog-listing__title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  color: var(--text-primary);
}

.blog-listing__description {
  max-width: 640px;
  margin-top: 20px;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

.blog-listing__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.blog-listing__empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 0;
  color: var(--text-muted);
  font-size: 1.0625rem;
}

/* ---------- Blog Card ---------- */
.blog-card {
  background-color: var(--bg-card);
  position: relative;
  overflow: hidden;
  transition: background-color 0.4s ease;
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  background-color: var(--bg-card-hover);
}

.blog-card:hover .blog-card__line {
  transform: scaleX(1);
}

.blog-card:hover .blog-card__image img {
  transform: scale(1.03);
}

.blog-card__image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: var(--bg-tertiary);
}

.blog-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out-expo);
}

.blog-card__content {
  padding: 32px 36px 40px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-card__date {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.blog-card__tag {
  color: var(--orange);
}

.blog-card__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.15;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.blog-card__excerpt {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.blog-card__meta {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px 16px;
}

.blog-card__author {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.blog-card__read-more {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
  transition: color 0.3s ease;
}

.blog-card:hover .blog-card__read-more {
  color: var(--orange-light);
}

.blog-card__line {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--orange), var(--orange-light));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease-out-expo);
}

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: 64px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.pagination__link {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
  transition: color 0.3s ease;
}

.pagination__link:hover {
  color: var(--orange-light);
}

.pagination__link--disabled {
  color: var(--charcoal);
}

.pagination__count {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ---------- Author Header ---------- */
.author-header__inner {
  display: flex;
  align-items: center;
  gap: 28px;
}

.author-header__image {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--orange);
  flex-shrink: 0;
}

.author-header__links {
  margin-top: 16px;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.author-header__links a {
  color: var(--orange);
}

/* ---------- Blog Post ---------- */
.blog-post {
  padding: calc(var(--nav-height) + 60px) 0 80px;
  background-color: var(--bg-primary);
}

.blog-post__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--orange);
  margin-bottom: 48px;
  transition: color 0.3s ease, gap 0.3s ease;
}

.blog-post__back:hover {
  color: var(--orange-light);
  gap: 12px;
}

.blog-listing__header .blog-post__back {
  margin-bottom: 32px;
}

.blog-post__header {
  max-width: var(--content-width);
  margin: 0 auto 48px;
}

.blog-post__date {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 16px;
}

.blog-post__dot {
  color: var(--text-muted);
}

.blog-post__tag:hover {
  color: var(--orange-light);
}

.blog-post__title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.05;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.blog-post__excerpt {
  font-size: 1.1875rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.blog-post__author {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--text-muted);
}

.blog-post__author a {
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.blog-post__author a:hover {
  color: var(--orange);
}

.blog-post__hero {
  max-width: 900px;
  margin: 0 auto 56px;
}

.blog-post__hero img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 2px;
}

.blog-post__hero figcaption,
.gh-content figcaption {
  margin-top: 12px;
  font-size: 0.875rem;
  line-height: 1.5;
  text-align: center;
  color: var(--text-muted);
}

/* ---------- Post Body (Ghost content) ----------
   Grid lets Ghost's wide and full-width cards break out of the text column. */
.gh-content {
  display: grid;
  grid-template-columns:
    [full-start] minmax(var(--container-padding), 1fr)
    [wide-start] minmax(0, calc((var(--wide-width) - var(--content-width)) / 2))
    [main-start] min(var(--content-width), calc(100% - var(--container-padding) * 2))
    [main-end] minmax(0, calc((var(--wide-width) - var(--content-width)) / 2))
    [wide-end] minmax(var(--container-padding), 1fr) [full-end];
}

.gh-content > * {
  grid-column: main-start / main-end;
}

.gh-content > .kg-width-wide {
  grid-column: wide-start / wide-end;
}

.gh-content > .kg-width-full {
  grid-column: full-start / full-end;
}

.gh-content > .kg-width-full img {
  width: 100%;
}

.gh-content h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.1;
  color: var(--text-primary);
  margin: 56px 0 20px;
}

.gh-content h3 {
  font-family: var(--font-display);
  font-size: clamp(1.375rem, 2.5vw, 1.75rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.15;
  color: var(--text-primary);
  margin: 40px 0 16px;
}

.gh-content h4,
.gh-content h5,
.gh-content h6 {
  font-family: var(--font-body);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 32px 0 12px;
}

.gh-content > h2:first-child,
.gh-content > h3:first-child {
  margin-top: 0;
}

.gh-content p,
.gh-content li {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.gh-content p {
  margin-bottom: 24px;
}

.gh-content strong {
  color: var(--text-primary);
  font-weight: 600;
}

.gh-content a {
  color: var(--orange);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.3s ease;
}

.gh-content a:hover {
  color: var(--orange-light);
}

.gh-content blockquote:not([class]) {
  border-left: 3px solid var(--orange);
  padding: 4px 0 4px 24px;
  margin: 32px 0;
  font-size: 1.125rem;
  font-style: italic;
  line-height: 1.7;
  color: var(--text-primary);
}

.gh-content blockquote:not([class]) p {
  font-size: inherit;
  color: inherit;
  margin-bottom: 0;
}

.gh-content blockquote.kg-blockquote-alt {
  margin: 48px 0;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-style: normal;
  letter-spacing: 0.03em;
  line-height: 1.15;
  text-align: center;
  color: var(--orange);
}

.gh-content ul,
.gh-content ol {
  padding-left: 24px;
  margin-bottom: 24px;
}

.gh-content li {
  margin-bottom: 8px;
}

.gh-content li::marker {
  color: var(--orange);
}

.gh-content code {
  font-size: 0.9em;
  background-color: var(--bg-tertiary);
  padding: 2px 6px;
  border-radius: 3px;
  color: var(--orange-light);
}

.gh-content pre {
  background-color: var(--bg-tertiary);
  padding: 24px;
  border-radius: 4px;
  overflow-x: auto;
  margin-bottom: 24px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.gh-content pre code {
  background: none;
  padding: 0;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.gh-content hr {
  border: none;
  height: 1px;
  background: rgba(255, 255, 255, 0.06);
  margin: 48px 0;
}

.gh-content figure {
  margin: 32px 0;
}

.gh-content img {
  height: auto;
  border-radius: 2px;
}

/* Wide tables scroll inside themselves instead of making the whole page
   scroll sideways on small screens (WCAG 1.4.10). */
.gh-content table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin-bottom: 24px;
}

.gh-content th,
.gh-content td {
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
  font-size: 0.9375rem;
  color: var(--text-secondary);
}

.gh-content th {
  color: var(--text-primary);
  font-weight: 600;
}

/* ---------- Ghost Cards on Dark ----------
   card_assets loads Ghost's default card styles; these adapt them to the dark palette. */
.gh-content .kg-bookmark-container {
  color: var(--text-primary);
  text-decoration: none;
  background-color: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 2px;
}

.gh-content .kg-bookmark-title {
  color: var(--text-primary);
}

.gh-content .kg-bookmark-description,
.gh-content .kg-bookmark-metadata {
  color: var(--text-secondary);
}

.gh-content .kg-callout-card {
  border-radius: 2px;
}

.gh-content .kg-callout-card p,
.gh-content .kg-callout-text {
  margin-bottom: 0;
}

.gh-content .kg-callout-card-grey,
.gh-content .kg-callout-card-white {
  background-color: var(--bg-card);
}

.gh-content .kg-callout-card-accent {
  background-color: var(--orange);
}

.gh-content .kg-callout-card-accent p,
.gh-content .kg-callout-card-accent .kg-callout-text {
  color: var(--bg-primary);
}

.gh-content .kg-toggle-card {
  background-color: var(--bg-card);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.gh-content .kg-toggle-heading-text {
  color: var(--text-primary);
}

.gh-content .kg-toggle-card svg {
  color: var(--text-secondary);
}

.gh-content .kg-btn,
.gh-content .kg-btn-accent {
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
}

.gh-content .kg-btn-accent {
  background-color: var(--orange);
  color: var(--bg-primary);
}

.gh-content .kg-product-card-container,
.gh-content .kg-file-card-container,
.gh-content .kg-audio-card {
  background-color: var(--bg-card);
  color: var(--text-primary);
  box-shadow: none;
}

.gh-content .kg-file-card a {
  text-decoration: none;
}

/* ---------- Author Box ---------- */
.author-box-list {
  max-width: var(--content-width);
  margin: 64px auto 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.author-box {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  padding: 28px 32px;
  background-color: var(--bg-card);
  border-left: 3px solid var(--orange);
}

.author-box__image {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.author-box__eyebrow {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 4px;
}

.author-box__name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.author-box__name:hover {
  color: var(--orange);
}

.author-box__bio {
  margin-top: 6px;
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

/* ---------- More Posts ---------- */
.more-posts {
  padding: 80px 0 120px;
  background-color: var(--bg-secondary);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.more-posts__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--text-primary);
  margin-bottom: 40px;
}

/* ---------- Error Page ---------- */
.error-page {
  padding: calc(var(--nav-height) + 120px) 0 160px;
  min-height: 80vh;
}

.error-page__title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.error-page__message {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.error-page__cta {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bg-primary);
  background-color: var(--orange);
  padding: 14px 32px;
  border-radius: 2px;
  transition: background-color 0.3s ease;
}

.error-page__cta:hover {
  background-color: var(--orange-light);
}

/* ---------- Footer ---------- */
.footer {
  padding: 80px 0 40px;
  background-color: #050505;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.footer__top {
  display: flex;
  justify-content: space-between;
  gap: 80px;
  margin-bottom: 80px;
}

.footer__brand {
  flex-shrink: 0;
}

.footer__logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.06em;
  margin-bottom: 12px;
}

.footer__logo-signal {
  color: var(--text-primary);
}

.footer__logo-forge {
  color: var(--orange);
}

.footer__tagline {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-style: italic;
}

.footer__links {
  display: flex;
  gap: 80px;
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer__col-title {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.footer__link {
  font-size: 0.875rem;
  color: var(--text-muted);
  transition: color 0.3s ease;
}

.footer__link:hover {
  color: var(--orange);
}

.footer__bottom {
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.footer__copyright {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* ---------- Animations ----------
   Only hidden when JS is running, so content never stays invisible. */
.js [data-animate] {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s var(--ease-out-quart), transform 0.8s var(--ease-out-quart);
}

.js [data-animate].is-visible {
  opacity: 1;
  transform: none;
}

/* Respect the OS "reduce motion" setting (WCAG 2.3.3) */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0s !important;
  }

  .js [data-animate] {
    opacity: 1;
    transform: none;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .blog-listing__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer__top {
    flex-direction: column;
    gap: 48px;
  }

  .footer__links {
    gap: 48px;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
    --container-padding: 20px;
  }

  .nav__links,
  .nav__cta {
    display: none;
  }

  .nav__toggle {
    display: flex;
  }

  .blog-listing {
    padding: calc(var(--nav-height) + 48px) 0 80px;
  }

  .blog-listing__header {
    margin-bottom: 48px;
  }

  .blog-listing__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .blog-card__content {
    padding: 24px 28px 32px;
  }

  .blog-post {
    padding: calc(var(--nav-height) + 32px) 0 64px;
  }

  .blog-post__back {
    margin-bottom: 32px;
  }

  .blog-post__header {
    margin-bottom: 32px;
  }

  .blog-post__hero {
    margin-bottom: 40px;
  }

  .gh-content h2 {
    margin: 40px 0 16px;
  }

  .gh-content h3 {
    margin: 32px 0 12px;
  }

  .author-box {
    flex-direction: column;
    padding: 24px;
  }

  .author-header__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  .more-posts {
    padding: 64px 0 80px;
  }

  .footer__links {
    flex-direction: column;
    gap: 32px;
  }

  .footer__bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .blog-card__title {
    font-size: 1.25rem;
  }

  .gh-content p,
  .gh-content li {
    font-size: 1rem;
  }

  .pagination__count {
    display: none;
  }
}
