/* ===== Mermaid diagrams on Obsidian Publish =====
   1. Scale down to the reading column when slightly too wide.
   2. Never shrink below readable size (min-width floor).
   3. When the floor is wider than the column, scroll horizontally
      instead of clipping. */
.mermaid {
  overflow-x: auto;
  overflow-y: hidden;
  max-width: 100%;
  padding-bottom: 0.5rem;          /* room for the scrollbar */
  -webkit-overflow-scrolling: touch;
}
.mermaid svg {
  max-width: 100% !important;      /* fit the column when possible */
  height: auto;
  min-width: 620px;                /* …but never below readable size */
}
/* narrow phones: allow the floor to relax a little */
@media (max-width: 700px) {
  .mermaid svg { min-width: 540px; }
}

/* ===== targeting.ai brand =====   (republished 2026-09-19: the CDN had cached a 404 for this file)
   The same two signals as the landing page: brand blue and a serif headline.
   Variables only (each one checked against publish.obsidian.md/app.css on
   2026-09-19), so a renamed variable is a no-op, never a broken page. */
body {
  --accent-h: 221;                 /* #2563EB = hsl(221 83% 53%); app.css ships 258 */
  --accent-s: 83%;
  --accent-l: 53%;
}
.published-container {
  /* ponytail: no font file is loaded (no request to Google, the rule
     targeting.ai follows), so without Newsreader installed this is Georgia.
     If that is not close enough, base64-embed landing_page_pro's
     client/public/fonts/newsreader-latin.woff2 in an @font-face here. */
  --h1-font: "Newsreader", Georgia, "Times New Roman", serif;   /* the page title follows --h1-font */
  --h2-font: var(--h1-font);
  --h1-weight: 500;
  --h2-weight: 500;               /* same as h1: under the Georgia fallback 600 turns bold and outweighs the title */
}

/* ===== Page title =====
   Publish prints the filename as the page title ("love-math",
   "00-social-dynamics"). Every essay opens with its own H1, so hide the
   filename wherever the note has one; a note without an H1 keeps it. */
.markdown-preview-sizer:has(.el-h1) .mod-header { display: none; }
