/* Post detail. Tokens come from tokens-aqua.css, which enqueue.php loads first. */
.post-progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; }
.post-progress-bar { display:block; height:100%; transform-origin:0 50%; transform:scaleX(0);
  background: var(--accent-amber); transition: transform .1s linear; }

.post-hero-inner { max-width: 46rem; margin: 0 auto; text-align: center; }
.post-kicker { display:inline-block; margin-bottom:.75rem; }
.post-meta { display:flex; gap:.5rem; justify-content:center; opacity:.7; font-size:.875rem; }

.post-layout { display:grid; grid-template-columns: 16rem minmax(0,45rem); gap:4rem;
  justify-content:center; padding: 4rem 1.5rem 6rem; }
.post-toc { position:sticky; top:6rem; align-self:start; }
.post-toc-list { list-style:none; margin:0; padding:0; display:grid; gap:.5rem; }
.post-toc-list a { opacity:.6; text-decoration:none; }
/* Nested h3 entries, emitted by post-toc.js only when the post's top level is h2. */
.post-toc-list .post-toc-sub { padding-left: 1rem; font-size: .9375em; }
.post-toc-list a.is-current { opacity:1; font-weight:600; }

/* min-w-0 on the body column: without it a wide <pre> or table widens the grid track
   and pushes the whole page sideways. */
.post-body { min-width: 0; }
.post-body :is(pre, table) { overflow-x: auto; display:block; max-width:100%; }
.post-body blockquote { font-family:'Instrument Serif', Georgia, serif; font-style:italic; }
.post-body img { max-width:100%; height:auto; }

@media (max-width: 60rem) {
  .post-layout { grid-template-columns: minmax(0,1fr); gap:2rem; }
  .post-toc { display:none; }          /* sticky TOC is desktop-only by design */
}

/* ─────────────────────────────────────────────────────────────────────────────
   THE REST OF THE PAGE. Everything above styles the progress bar, the TOC and
   the body column's overflow behaviour; ten of the classes single.php emits had
   no rule anywhere in the theme, so the post rendered as unstyled flow.

   THE FIRST THING THAT HAS TO BE UNDONE IS .hero. <header class="hero post-hero">
   inherits height:100vh AND overflow:hidden from style-aqua.css — built for the
   full-viewport marketing heroes with video behind them. On a post that clips
   the title, the meta and the featured image at the fold and leaves a tall black
   box, which is what "looking awful" was. Same trap the assistant pages hit;
   template-legal.php avoids it by not using .hero at all.

   Section rhythm follows the blog listing: dark hero -> light body, the site's
   established alternation, and long-form reads better on light. */

.post-single { background: var(--surface-alt); }

.post-hero {
  height: auto;                 /* was 100vh */
  overflow: visible;            /* was hidden — this is what clipped the page */
  background: var(--dark-bg);
  padding: 0 var(--space-3) var(--space-5);
}
.post-hero-inner { max-width: 46rem; margin: var(--space-5) auto 0; text-align: center; }

/* Matches .blog-hero #nav, so the bar sits identically on the listing and on a
   post. The hero's own padding is removed from the top because the nav now
   provides it. */
.post-hero #nav { padding: var(--space-2) var(--space-5); }

/* PHONE PADDING. The rule above out-specifies the main nav's own phone steps in
   style-aqua.css (#nav alone), so without these this page kept 64px side padding at
   every width and scrolled sideways on phones: 43px at 320, 3px at 360 on /nl/. */
@media (max-width: 640px) {
  .post-hero #nav {
    padding-left: var(--space-3);
    padding-right: var(--space-3);
  }
}

@media (max-width: 380px) {
  .post-hero #nav {
    padding-left: var(--space-2);
    padding-right: var(--space-2);
  }
}

.post-kicker {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-on-dark);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  text-decoration: none;
  transition: background 0.2s ease;
}
.post-kicker:hover { background: rgba(255, 255, 255, 0.2); }

.post-title {
  font-family: 'Inter', sans-serif;
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-on-dark);
  margin: var(--space-3) 0 var(--space-2);
}

.post-meta { color: rgba(255, 255, 255, 0.6); opacity: 1; }
.post-meta-sep { color: rgba(255, 255, 255, 0.35); }

/* The featured image. Unstyled it rendered at its intrinsic size, flush to the
   top-left of the clipped hero — the single most visible symptom. */
.post-hero-media {
  max-width: 1080px;
  margin: var(--space-5) auto calc(var(--space-6) * -1);
  padding: 0 var(--space-3);
}
.post-hero-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius-card);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
}

/* Body column ------------------------------------------------------------- */
.post-layout { padding-top: var(--space-7); }
.post-toc-list a { color: var(--text-secondary); }
.post-toc-list a.is-current { color: var(--text-primary); }

.post-body {
  font-family: 'Inter', sans-serif;
  font-size: 17px;
  line-height: 1.75;
  color: var(--text-primary);
}
.post-body > * + * { margin-top: var(--space-3); }
.post-body h2 {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin-top: var(--space-5);
}
.post-body h3 { font-size: 20px; font-weight: 700; margin-top: var(--space-4); }
.post-body a { color: var(--accent-steel); text-underline-offset: 3px; }
.post-body a:hover { color: var(--text-primary); }
.post-body ul, .post-body ol { padding-left: 1.4em; }
.post-body li + li { margin-top: 8px; }
.post-body img { border-radius: var(--radius-ui); }

/* Stand-in for a body image we do not have (reference/replace-dead-post-images.php
   swapped six dead askingtips.com hotlinks for it). Same place and shape as the
   image it replaces, painted with the pastel mesh the blog cards use when a post
   has no featured image (blog-page-aqua.css .blog-thumb-*), so "no image" looks
   the same everywhere on the blog. */
.post-body .post-media-gradient {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-ui);
  /* The mesh fades to near-white, and the post body is light: without an edge the
     block's lower half dissolves into the page. */
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
}
.post-media-gradient-green {
  background:
    radial-gradient(at 15% 20%, #d4f0dc 0%, transparent 55%),
    radial-gradient(at 85% 15%, #b8e8c8 0%, transparent 55%),
    radial-gradient(at 50% 90%, #e8f7ec 0%, transparent 55%),
    #fdfcfb;
}
.post-media-gradient-peach {
  background:
    radial-gradient(at 15% 20%, #ffd9c4 0%, transparent 55%),
    radial-gradient(at 85% 15%, #ffb8a3 0%, transparent 55%),
    radial-gradient(at 50% 90%, #ffeedc 0%, transparent 55%),
    #fdfcfb;
}
.post-media-gradient-lavender {
  background:
    radial-gradient(at 15% 20%, #d4d9ff 0%, transparent 55%),
    radial-gradient(at 85% 15%, #b8c4ff 0%, transparent 55%),
    radial-gradient(at 50% 90%, #e8eaff 0%, transparent 55%),
    #fdfcfb;
}
.post-media-gradient-rose {
  background:
    radial-gradient(at 15% 20%, #ffd9e8 0%, transparent 55%),
    radial-gradient(at 85% 15%, #ffb8d4 0%, transparent 55%),
    radial-gradient(at 50% 90%, #ffeef5 0%, transparent 55%),
    #fdfcfb;
}
.post-body blockquote {
  font-size: 22px;
  line-height: 1.5;
  color: var(--text-primary);
  border-left: 3px solid var(--accent-amber);
  padding-left: var(--space-3);
  margin-left: 0;
}
.post-body :is(pre, code) { font-size: 14px; }
.post-body pre {
  background: #0f172a;
  color: #e2e8f0;
  padding: var(--space-3);
  border-radius: var(--radius-ui);
}

/* Footer ------------------------------------------------------------------ */
.post-footer {
  max-width: 45rem;
  margin: 0 auto;
  padding: 0 1.5rem var(--space-6);
}
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: var(--space-4); }
.post-tags a {
  font-family: 'Inter', sans-serif;
  font-size: 12.5px;
  color: var(--text-secondary);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 5px 12px;
  text-decoration: none;
}
.post-tags a:hover { color: var(--text-primary); border-color: var(--accent-steel); }

.post-adjacent {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
}
.post-prev, .post-next { max-width: 48%; }
.post-next { margin-left: auto; text-align: right; }
.post-adjacent a {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text-primary);
  text-decoration: none;
}
.post-adjacent a:hover { color: var(--accent-steel); }

.post-pagelinks { margin-top: var(--space-3); display: flex; gap: 8px; }

@media (max-width: 60rem) {
  .post-hero { padding: var(--space-5) var(--space-2) var(--space-4); }
  .post-hero-media { margin-bottom: calc(var(--space-5) * -1); padding: 0 var(--space-2); }
  .post-layout { padding-top: var(--space-6); }
  .post-adjacent { flex-direction: column; }
  .post-prev, .post-next { max-width: none; text-align: left; margin-left: 0; }
}
