/* ==========================================================================
   wanji — screen.css
   Edit the tokens in :root to restyle the whole theme.
   ========================================================================== */

/* Apercu (The Entente / Colophon), converted from your font files.
   Latin characters only, to keep each file around 22 KB. */
@font-face { font-family: "Apercu"; src: url("../fonts/apercu-regular.woff") format("woff"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Apercu"; src: url("../fonts/apercu-italic.woff") format("woff"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Apercu"; src: url("../fonts/apercu-medium.woff") format("woff"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Apercu"; src: url("../fonts/apercu-bold.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Apercu"; src: url("../fonts/apercu-bold-italic.woff") format("woff"); font-weight: 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Apercu Mono"; src: url("../fonts/apercu-mono.woff") format("woff"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
    /* Fonts — Ghost's "Typography" setting overrides heading/body if set */
    --font-sans: "Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-serif: "Iowan Old Style", "Charter", "Palatino Linotype", Georgia, serif;   /* swap in below to go back to serif */
    --font-heading: var(--gh-font-heading, var(--font-sans));
    --font-body: var(--gh-font-body, var(--font-sans));
    --font-ui: var(--font-sans);
    --font-mono: "Apercu Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

    /* Colors — accent comes from Ghost Admin → Design → Brand */
    --accent: var(--ghost-accent-color, #0f567d);
    --accent-text: var(--accent);   /* accent used for text; lightened in dark mode */
    --bg: #ffffff;
    --surface: #f2f2f0;
    --ink: #111111;
    --ink-soft: #4a4a4a;
    --ink-faint: #8a8a8a;
    --rule: #e6e6e6;

    /* Playful tile colors for posts without an image */
    --pop-1: #0f567d;   /* logo blue */
    --pop-2: #f5d547;   /* sunshine */
    --pop-3: #111111;   /* ink */
    --pop-4: #ef6f4f;   /* coral */

    /* Layout */
    --content: 680px;
    --wide: 1100px;
    --page: 1100px;
    --gutter: clamp(16px, 4vw, 32px);
    --radius: 6px;

    color-scheme: light;
}

/* Dark scheme: forced, or following the device when set to Auto */
html[data-color-scheme="Dark"] {
    --bg: #0e0e0e;
    --surface: #1a1a1a;
    --ink: #f2f2f2;
    --ink-soft: #b5b5b5;
    --ink-faint: #7d7d7d;
    --rule: #262626;
    --pop-3: #2a2a2a;
    --accent-text: color-mix(in srgb, var(--accent) 45%, #ffffff);
    color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
    html[data-color-scheme="Auto"] {
        --bg: #0e0e0e;
        --surface: #1a1a1a;
        --ink: #f2f2f2;
        --ink-soft: #b5b5b5;
        --ink-faint: #7d7d7d;
        --rule: #262626;
        --pop-3: #2a2a2a;
            color-scheme: dark;
    }
}

/* Base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-ui);
    font-size: 1rem;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img, video, iframe { max-width: 100%; }
img { height: auto; display: block; }

a { color: inherit; text-decoration-color: var(--rule); text-underline-offset: 0.2em; }
a:hover { color: var(--accent-text); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin: 0;
}

.site { display: flex; flex-direction: column; min-height: 100vh; }
.site-main { flex: 1; }

.wrap {
    width: min(var(--page), 100% - var(--gutter) * 2);
    margin-inline: auto;
}

/* Buttons & small UI
   ========================================================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4em;
    padding: 0.7em 1.2em;
    border: 0;
    border-radius: var(--radius);
    background: var(--accent);
    color: #fff;
    font: 600 0.95rem/1 var(--font-ui);
    text-decoration: none;
    cursor: pointer;
    transition: filter 0.15s ease;
}
.btn:hover { color: #fff; filter: brightness(1.08); }
.btn-small { padding: 0.55em 0.9em; font-size: 0.875rem; }

.icon-btn {
    display: inline-grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--ink-soft);
    cursor: pointer;
}
.icon-btn:hover { background: var(--surface); color: var(--ink); }

.link-quiet { color: var(--ink-soft); text-decoration: none; font-size: 0.9rem; }

.tag {
    color: var(--accent-text);
    font: 600 0.75rem/1 var(--font-ui);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
}

.badge {
    padding: 0.25em 0.5em;
    border-radius: 999px;
    background: var(--surface);
    color: var(--ink-soft);
    font-size: 0.7rem;
    font-weight: 600;
}

/* Header: blinking logo top left, menu beside it, actions on the right
   ========================================================================== */

.header-inner {
    display: flex;
    align-items: center;
    gap: 28px;
    padding-block: 20px;
}

.site-title {
    display: inline-flex;
    flex: none;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    text-decoration: none;
    letter-spacing: -0.02em;
}
.site-title:hover { color: inherit; }
.site-header .logo { height: clamp(44px, 5vw, 60px); transition: transform 0.25s ease; }
.site-title:hover .logo { transform: rotate(-6deg) scale(1.04); }

.header-row {
    display: flex;
    flex: 1;
    align-items: center;
    gap: 12px 28px;
    min-width: 0;
}

.site-nav .nav,
.footer-nav .nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.site-nav .nav a {
    color: var(--ink);
    font-size: 1.05rem;
    font-weight: 500;
    text-decoration: none;
}
.site-nav .nav a:hover { color: var(--accent-text); }
.site-nav .nav-current a { text-decoration: underline wavy var(--accent-text) 2px; text-underline-offset: 0.35em; }

.header-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }

/* Light/dark toggle: moon in light mode, sun in dark mode */
.theme-toggle .icon-sun { display: none; }
html[data-color-scheme="Dark"] .theme-toggle .icon-moon { display: none; }
html[data-color-scheme="Dark"] .theme-toggle .icon-sun { display: block; }
@media (prefers-color-scheme: dark) {
    html[data-color-scheme="Auto"] .theme-toggle .icon-moon { display: none; }
    html[data-color-scheme="Auto"] .theme-toggle .icon-sun { display: block; }
}
.theme-toggle svg { transition: transform 0.3s ease; }
.theme-toggle:hover svg { transform: rotate(-20deg); }
@media (prefers-reduced-motion: reduce) { .theme-toggle svg { transition: none; } }

/* Phones: logo + actions on top, menu on its own line underneath */
@media (max-width: 640px) {
    .header-inner { flex-wrap: wrap; gap: 12px 16px; padding-block: 14px; }
    .header-row { display: contents; }
    .header-actions { order: 1; }
    .site-nav { order: 2; flex-basis: 100%; }
    .site-nav .nav { gap: 6px 22px; }
}

/* The wanji mark: open + closed eyes stacked; blink.js adds .is-blinking to swap them.
   Light/dark copies are picked by the color scheme (see --logo-dark). */
.logo {
    position: relative;
    display: inline-block;
    flex: none;
    height: 40px;
    aspect-ratio: 213 / 192;
}
.logo-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transition: opacity 80ms ease-in-out;
}
.logo-closed { opacity: 0; }
.logo.is-blinking .logo-open { opacity: 0; }
.logo.is-blinking .logo-closed { opacity: 1; }
.logo-on-dark { display: none; }
html[data-color-scheme="Dark"] .logo-on-light { display: none; }
html[data-color-scheme="Dark"] .logo-on-dark { display: block; }
@media (prefers-color-scheme: dark) {
    html[data-color-scheme="Auto"] .logo-on-light { display: none; }
    html[data-color-scheme="Auto"] .logo-on-dark { display: block; }
}
@media (prefers-reduced-motion: reduce) {
    .logo-img { transition: none; }
}

/* Hero
   ========================================================================== */

.home-top { height: clamp(24px, 4vw, 48px); }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* Hand-drawn doodles in the footer: small, each bobbing on its own beat, wiggle on hover */
.doodles {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 6px 14px;
}
.doodle {
    --r: 0deg;
    --lift: -4px;
    position: relative;
    display: block;
    height: 46px;
    transform: rotate(var(--r));
    transform-origin: 50% 90%;
    animation: doodle-bob 4.5s ease-in-out infinite;
}
.doodle img { height: 100%; width: auto; }
.doodle .on-dark { display: none; }
.doodle:hover { animation: doodle-wiggle 0.6s ease-in-out; }

.doodle:nth-child(1) { --r: -5deg; animation-delay: -0.4s; }
.doodle:nth-child(2) { --r: 4deg;  animation-delay: -2.1s; height: 40px; }
.doodle:nth-child(3) { --r: -3deg; animation-delay: -1.2s; }
.doodle:nth-child(4) { --r: 6deg;  animation-delay: -3.0s; }
.doodle:nth-child(5) { --r: -6deg; animation-delay: -0.9s; height: 40px; }
.doodle:nth-child(6) { --r: 3deg;  animation-delay: -2.6s; }

@keyframes doodle-bob {
    0%, 100% { transform: translateY(0) rotate(var(--r)); }
    50%      { transform: translateY(var(--lift)) rotate(calc(var(--r) * -0.4)); }
}
@keyframes doodle-wiggle {
    0%, 100% { transform: rotate(var(--r)) scale(1.06); }
    25%      { transform: rotate(calc(var(--r) - 9deg)) scale(1.08); }
    75%      { transform: rotate(calc(var(--r) + 9deg)) scale(1.08); }
}
@media (prefers-reduced-motion: reduce) {
    .doodle, .doodle:hover { animation: none; }
}

/* Light/dark copies of drawn images (doodles) */
html[data-color-scheme="Dark"] .doodle .on-light { display: none; }
html[data-color-scheme="Dark"] .doodle .on-dark { display: block; }
@media (prefers-color-scheme: dark) {
    html[data-color-scheme="Auto"] .doodle .on-light { display: none; }
    html[data-color-scheme="Auto"] .doodle .on-dark { display: block; }
}

/* Subscribe form
   ========================================================================== */

.subscribe { margin-top: 28px; max-width: 460px; }
.subscribe-row { display: flex; gap: 8px; }
.subscribe input {
    flex: 1;
    min-width: 0;
    padding: 0.7em 0.9em;
    border: 1px solid var(--rule);
    border-radius: var(--radius);
    background: var(--bg);
    color: var(--ink);
    font: 1rem var(--font-ui);
}
.subscribe input:focus { outline: none; border-color: var(--accent); }

.btn-loading, .form-msg { display: none; }
.subscribe.loading .btn-label { display: none; }
.subscribe.loading .btn-loading { display: inline; }
.form-msg { margin: 10px 0 0; font-size: 0.875rem; }
.subscribe.success .form-success { display: block; color: var(--ink-soft); }
.subscribe.error .form-error { display: block; color: #c0392b; }

/* Topic filters
   ========================================================================== */

.filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 32px;
    padding-block: 8px 36px;
}
.filter {
    color: var(--ink);
    font-size: 1.15rem;
    font-weight: 500;
    text-decoration: none;
}
.filter:hover { color: var(--accent-text); }
.filter[aria-current="page"] {
    text-decoration: underline wavy var(--accent-text) 2px;
    text-underline-offset: 0.35em;
}

/* Tiles: edge-to-edge squares with chunky titles
   ========================================================================== */

.feed-tiles {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 900px) { .feed-tiles { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1400px) { .feed-tiles { grid-template-columns: repeat(4, 1fr); } }
.feed-tiles .feed-empty { grid-column: 1 / -1; padding-block: 48px; text-align: center; }

.tile-link {
    position: relative;
    display: block;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--tile-bg, var(--pop-3));
    color: var(--tile-ink, #fff);
    text-decoration: none;
}
.tile-link:hover { color: var(--tile-ink, #fff); }
.tile-link:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }

.tile-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.has-image .tile-link::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.6), rgba(0,0,0,0.15) 70%);
    transition: opacity 0.3s ease;
}
.tile-link:hover .tile-img { transform: scale(1.05); }
.has-image .tile-link:hover::after { opacity: 0.6; }

.tile-body {
    position: absolute;
    inset: auto 0 0 0;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: clamp(14px, 2.4vw, 32px);
}
.tile-tag {
    font: 600 0.72rem/1 var(--font-ui);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0.85;
}
.tile-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    overflow: hidden;
    font: 700 clamp(1.35rem, 3.4vw, 2.9rem)/0.98 var(--font-heading);
    letter-spacing: -0.035em;
    overflow-wrap: anywhere;
}
@media (min-width: 1400px) { .tile-title { font-size: clamp(1.6rem, 2.4vw, 2.9rem); } }
.has-image .tile-title { text-shadow: 0 1px 12px rgba(0,0,0,0.25); }

.tile-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 1;
    padding: 0.35em 0.7em;
    border-radius: 999px;
    background: rgba(255,255,255,0.92);
    color: #111;
    font: 600 0.7rem/1 var(--font-ui);
}

/* Posts without an image get a pop of color, rotating through the palette */
.tile.no-image:nth-child(4n+1) .tile-link { --tile-bg: var(--pop-1); }
.tile.no-image:nth-child(4n+2) .tile-link { --tile-bg: var(--pop-2); --tile-ink: #111; }
.tile.no-image:nth-child(4n+3) .tile-link { --tile-bg: var(--pop-3); }
.tile.no-image:nth-child(4n+4) .tile-link { --tile-bg: var(--pop-4); --tile-ink: #111; }
.tile.no-image .tile-body { inset: 0; justify-content: flex-end; }
.tile.no-image .tile-link:hover .tile-title { transform: rotate(-2deg); }
.tile-title { transition: transform 0.25s ease; }

.feed-tiles + .wrap .pagination { border-top: 0; padding-top: 40px; }

/* Homepage sign-up band
   ========================================================================== */

.cta-band {
    margin-top: 24px;
    padding-block: clamp(64px, 10vw, 128px);
    background: var(--accent);
    color: #fff;
    text-align: center;
}
.cta-band-title {
    max-width: 16ch;
    margin-inline: auto;
    font-size: clamp(2rem, 5.5vw, 4.25rem);
    font-weight: 700;
    line-height: 0.98;
    letter-spacing: -0.04em;
    transform: rotate(-1.5deg);
}
.cta-band .subscribe { margin: 32px auto 0; }
.cta-band .subscribe input { border-color: transparent; background: #fff; color: #111; }
.cta-band .btn { background: #111; }
.cta-band .form-success, .cta-band .form-error { color: #fff; }

/* Post feed
   ========================================================================== */

.feed { padding-block: 8px 48px; }

.feed-list .post-card {
    display: grid;
    grid-template-columns: 1fr 200px;
    gap: 32px;
    align-items: start;
    padding-block: 32px;
    border-top: 1px solid var(--rule);
}
.feed-list .post-card.no-image { grid-template-columns: 1fr; }
.feed-list .post-card-image { order: 2; }
.feed-list .post-card-body { max-width: 640px; }

.feed-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
    gap: 48px 32px;
    padding-top: 32px;
    border-top: 1px solid var(--rule);
}
.feed-grid .post-card-image { margin-bottom: 16px; }

.post-card-image img {
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    border-radius: var(--radius);
    background: var(--surface);
}

.meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 12px;
    color: var(--ink-faint);
    font-size: 0.8rem;
}

.post-card-title {
    margin-top: 10px;
    font-size: clamp(1.35rem, 2.6vw, 1.65rem);
}
.post-card-title a { text-decoration: none; }

.post-card-excerpt {
    margin: 10px 0 0;
    color: var(--ink-soft);
    font-family: var(--font-body);
    font-size: 1.05rem;
    line-height: 1.55;
}

.post-card-foot { margin: 12px 0 0; color: var(--ink-faint); font-size: 0.8rem; }

.feed-empty { color: var(--ink-faint); }

@media (max-width: 640px) {
    .feed-list .post-card { grid-template-columns: 1fr; gap: 16px; padding-block: 28px; }
    .feed-list .post-card-image { order: 0; }
}

/* Pagination (Ghost's {{pagination}} markup) */
.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-block: 24px 64px;
    border-top: 1px solid var(--rule);
    color: var(--ink-faint);
    font-size: 0.9rem;
}
.pagination a { color: var(--ink); text-decoration: none; }
.pagination a:hover { color: var(--accent-text); }

/* Archive headers (tag, author)
   ========================================================================== */

.archive-header { padding-block: clamp(32px, 6vw, 72px) 28px; text-align: center; }
.archive-header .archive-description { margin-inline: auto; }
.archive-header .author-links { justify-content: center; }
.author-avatar { margin-inline: auto; }
.archive-kicker { margin: 0 0 8px; color: var(--accent-text); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.archive-title { font-size: clamp(2.4rem, 7vw, 5rem); font-weight: 700; line-height: 0.95; letter-spacing: -0.045em; }
.archive-description { max-width: 60ch; margin: 14px 0 0; color: var(--ink-soft); font-family: var(--font-body); font-size: 1.15rem; }
.author-avatar { width: 80px; height: 80px; margin-bottom: 20px; border-radius: 50%; object-fit: cover; }
.author-links { display: flex; gap: 16px; margin: 16px 0 0; color: var(--ink-faint); font-size: 0.9rem; }
.author-links:empty { display: none; }

/* Article layout — a grid with main / wide / full tracks,
   so editor cards can break out of the reading column.
   ========================================================================== */

.article,
.gh-content {
    display: grid;
    grid-template-columns:
        [full-start] minmax(var(--gutter), 1fr)
        [wide-start] minmax(0, calc((var(--wide) - var(--content)) / 2))
        [main-start] min(var(--content), 100% - var(--gutter) * 2)
        [main-end] minmax(0, calc((var(--wide) - var(--content)) / 2))
        [wide-end] minmax(var(--gutter), 1fr)
        [full-end];
}
.article > *,
.gh-content > * { grid-column: main; }
.article > .gh-content { grid-column: full; }

.article { padding-bottom: 48px; }

.article-header { padding-block: clamp(48px, 8vw, 88px) 32px; }
.article-title { margin-top: 14px; font-size: clamp(2.4rem, 6.5vw, 4rem); font-weight: 700; line-height: 1; letter-spacing: -0.04em; }
.article-excerpt { margin: 18px 0 0; color: var(--ink-soft); font-family: var(--font-body); font-size: 1.3rem; line-height: 1.45; }
.article-byline {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 8px;
    margin-top: 24px;
    color: var(--ink-faint);
    font-size: 0.875rem;
}
.article-byline a { color: var(--ink-soft); text-decoration: none; }
.page-template .article-header:only-child { padding-bottom: 0; }

.article-image { grid-column: wide; margin: 0 0 48px; }
.article-image img { width: 100%; border-radius: var(--radius); }

figcaption {
    margin-top: 10px;
    color: var(--ink-faint);
    font-size: 0.85rem;
    text-align: center;
}

/* Post content
   ========================================================================== */

.gh-content {
    font-family: var(--font-body);
    font-size: 1.125rem;
    line-height: 1.7;
}

.gh-content > * + * { margin-top: 1.5em; margin-bottom: 0; }
.gh-content > :first-child { margin-top: 0; }

.gh-content > h2 { margin-top: 1.6em; font-size: 1.75rem; }
.gh-content > h3 { margin-top: 1.75em; font-size: 1.4rem; }
.gh-content > h4 { margin-top: 1.5em; font-size: 1.15rem; }
.gh-content > h2 + *, .gh-content > h3 + *, .gh-content > h4 + * { margin-top: 0.6em; }

.gh-content a { color: var(--accent-text); text-decoration-color: currentColor; }

.gh-content ul, .gh-content ol { padding-left: 1.3em; }
.gh-content li + li { margin-top: 0.4em; }

.gh-content blockquote:not([class]) {
    margin-inline: 0;
    padding-left: 1.1em;
    border-left: 3px solid var(--accent);
    font-style: italic;
}

.gh-content blockquote.kg-blockquote-alt {
    margin-inline: 0;
    font-size: 1.5em;
    font-style: italic;
    line-height: 1.4;
    text-align: center;
    color: var(--ink-soft);
}

.gh-content hr {
    width: 100%;
    height: 1px;
    border: 0;
    background: var(--rule);
    margin-block: 2.5em;
}

.gh-content code {
    padding: 0.15em 0.35em;
    border-radius: 4px;
    background: var(--surface);
    font: 0.85em var(--font-mono);
}

.gh-content pre {
    overflow-x: auto;
    padding: 1.2em 1.4em;
    border-radius: var(--radius);
    background: #1c1b19;
    color: #ecebe6;
    font: 0.85rem/1.6 var(--font-mono);
}
.gh-content pre code { padding: 0; background: none; font-size: inherit; color: inherit; }

.gh-content table { border-collapse: collapse; width: 100%; font-family: var(--font-ui); font-size: 0.9rem; }
.gh-content th, .gh-content td { padding: 0.6em 0.8em; border-bottom: 1px solid var(--rule); text-align: left; }

.gh-content figure { margin-inline: 0; }
.gh-content figure img { border-radius: var(--radius); }

/* Editor card widths — required by Ghost */
.gh-content .kg-width-wide { grid-column: wide; }
.gh-content .kg-width-full { grid-column: full; }
.gh-content .kg-width-full img { width: 100%; border-radius: 0; }
.gh-content .kg-width-full figcaption { padding-inline: var(--gutter); }

/* Ghost's own card styles (card_assets) pick up these */
.gh-content .kg-callout-card,
.gh-content .kg-toggle-card,
.gh-content .kg-product-card,
.gh-content .kg-bookmark-card { font-family: var(--font-ui); font-size: 1rem; }

/* Members CTA + comments
   ========================================================================== */

.cta {
    margin-top: 64px;
    padding: 32px;
    border-radius: var(--radius);
    background: var(--surface);
}
.cta-title { font-size: 1.4rem; }
.cta .subscribe { margin-top: 16px; }

.article-comments { margin-top: 64px; }

/* Previous / next */
.post-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding-block: 32px 72px;
    border-top: 1px solid var(--rule);
}
.post-nav-link { display: flex; flex-direction: column; gap: 6px; text-decoration: none; }
.post-nav-link.next { grid-column: 2; text-align: right; }
.post-nav-label { color: var(--ink-faint); font-size: 0.8rem; }
.post-nav-title { font-family: var(--font-heading); font-size: 1.15rem; font-weight: 600; }
@media (max-width: 640px) {
    .post-nav { grid-template-columns: 1fr; }
    .post-nav-link.next { grid-column: 1; text-align: left; }
}

/* Error page
   ========================================================================== */

.error { padding-block: 96px; text-align: center; }
.error-code { margin: 0; color: var(--accent-text); font: 700 4rem/1 var(--font-heading); }
.error-message { margin: 16px 0 32px; font-size: 1.5rem; font-weight: 500; color: var(--ink-soft); }

/* Footer
   ========================================================================== */

.site-footer { color: var(--ink-faint); font-size: 0.85rem; }
.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px 32px;
    padding-block: 32px 36px;
}
.footer-inner p { margin: 0; }
.footer-inner a { color: var(--ink-soft); text-decoration: none; }
.footer-inner a:hover { color: var(--accent-text); }

.footer-brand { display: inline-flex; align-items: center; gap: 10px; }
.footer-inner .doodles { margin-right: auto; padding-top: 8px; }
.footer-brand .logo { height: 26px; }


.footer-nav .nav { gap: 4px 16px; }
