/* Notion export content rendered inline (replaces the old iframes). */

.notion-content { max-width: none !important; margin: 0 !important; }
.notion-content img, .notion-content video { max-width: 100% !important; height: auto !important; }
.notion-content figure { margin: 1.25em 0; }
.notion-content { overflow-wrap: anywhere; }
.notion-content table { display: block; max-width: 100%; overflow-x: auto; }
.week-content-blog { min-width: 0; }

/* custom.css forces the site font on everything; keep code monospaced */
#wrapper .notion-content code, #wrapper .notion-content pre, #wrapper .notion-content pre *,
#wrapper .notion-content .code, #wrapper .notion-content .mono {
    font-family: "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace !important;
}

/* ---- Type scale & hierarchy (body 17px, ~1.25 ratio) ---- */
#wrapper .notion-content, #wrapper .notion-content .page-body, #wrapper .notion-content .page-body p, #wrapper .notion-content .page-body li, #wrapper .notion-content .page-body div { font-size: 17px !important; line-height: 1.65; }
#wrapper .notion-content p, #wrapper .notion-content li { font-weight: 400; color: #2b2b2b; }
#wrapper .notion-content h1, #wrapper .notion-content h2, #wrapper .notion-content h3, #wrapper .notion-content h4 { font-weight: 600 !important; color: #1a1a1a; line-height: 1.25; letter-spacing: -0.01em; }
#wrapper .notion-content h1.page-title { font-size: 32px !important; letter-spacing: -0.02em; margin: 0 0 8px 0; padding: 0 !important; }
#wrapper .notion-content > article > header { margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid rgba(0,0,0,0.12); }
#wrapper .notion-content .page-body > :first-child { margin-top: 0 !important; }
#wrapper .notion-content .page-body h1 { font-size: 26px !important; margin: 56px 0 12px 0; }
#wrapper .notion-content .page-body h2 { font-size: 21px !important; margin: 40px 0 8px 0; }
#wrapper .notion-content .page-body h3 { font-size: 17px !important; margin: 28px 0 6px 0; }
#wrapper .notion-content p { margin: 0 0 12px 0; }
#wrapper .notion-content ul, #wrapper .notion-content ol { margin: 0 0 12px 0; }
#wrapper .notion-content figcaption { font-size: 14px !important; color: #777; margin-top: 6px; }
/* readable line length for text; media can use the full width */
#wrapper .notion-content p, #wrapper .notion-content ul, #wrapper .notion-content ol, #wrapper .notion-content blockquote { max-width: 70ch; }

/* ---- Images: left-aligned by default. Add class "center" to a figure to centre it. ---- */
#wrapper .notion-content figure.image { text-align: left !important; margin: 16px 0 24px 0; }
#wrapper .notion-content figure.image img { display: block; margin-left: 0; margin-right: auto; }
#wrapper .notion-content figure.image.center { text-align: center !important; }
#wrapper .notion-content figure.image.center img { margin-left: auto; }

/* ---- Code: dark blocks (Prism "tomorrow" theme), light inline chips ---- */
#wrapper .notion-content pre { background: #1e1e1e !important; color: #e6e6e6 !important; border: 0 !important; border-radius: 6px !important; padding: 16px 18px !important; margin: 12px 0 20px 0 !important; font-size: 14px !important; line-height: 1.55 !important; overflow-x: auto !important; white-space: pre !important; tab-size: 4; max-width: 100%; color-scheme: dark; }
#wrapper .notion-content pre code { background: none !important; border: 0 !important; padding: 0 !important; color: inherit !important; font-size: 14px !important; white-space: pre !important; text-shadow: none !important; }
#wrapper .notion-content :not(pre) > code { background: #E2DFD7 !important; color: #1a1a1a !important; border: 0 !important; border-radius: 4px !important; padding: 0.1em 0.4em !important; font-size: 0.88em !important; }

/* ---- Image layout (sizes set by assets/js/image-layout.js) ---- */
#wrapper .notion-content .column-list.img-row { display: flex !important; flex-wrap: wrap; gap: 12px; justify-content: flex-start; align-items: flex-start; }
#wrapper .notion-content .column-list.img-row figure { margin: 0 !important; }
/* fallback before the script runs */
#wrapper .notion-content figure.image img { max-height: 360px; width: auto; }
/* phones: stack text/image columns so images are not squeezed into thumbnails */
@media screen and (max-width: 736px) {
    #wrapper .notion-content .column-list:not(.img-row) { display: block !important; }
    #wrapper .notion-content .column-list:not(.img-row) > .column { width: 100% !important; padding: 0 !important; }
}

/* Images always sit on their own line. The template styles .image as inline-block, which made
   images inside list items break sentences (words wrapped around and below the picture). */
#wrapper .notion-content figure.image { display: block !important; }
