/* Mr. 6 Ghost theme — matches mr6.com aesthetic.
   All colors are inlined (Ghost themes can't share mr6.com's CSS vars). */

:root {
    --bg:          #F0F4FA;
    --bg-white:    #FFFFFF;
    --text:        #0A0F1E;
    --muted:       #5A6580;
    --accent:      #1A5CFF;
    --accent-glow: #4D8AFF;
    --accent-dark: #0D3FCC;
    --border:      #D4DCED;
    --tag-bg:      #E8F0FF;
    --surface:     #E4EAF5;

    --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-serif:   'Source Serif 4', Georgia, serif;
}

* { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; }
body {
    margin: 0;
    background-color: var(--bg);
    /* Per-page bubble background — position, size, opacity, and color are
       all seeded from a URL hash in default.hbs. Fallbacks keep the ATOPAI
       layout for the no-JS case. */
    background-image:
        radial-gradient(circle at var(--m6-b1-x, 10%) var(--m6-b1-y, 20%), rgba(var(--m6-b1-c,  26, 92,255), var(--m6-b1-o, 0.12)) 0%, transparent var(--m6-b1-r, 40%)),
        radial-gradient(circle at var(--m6-b2-x, 90%) var(--m6-b2-y, 10%), rgba(var(--m6-b2-c,  77,138,255), var(--m6-b2-o, 0.15)) 0%, transparent var(--m6-b2-r, 35%)),
        radial-gradient(circle at var(--m6-b3-x, 50%) var(--m6-b3-y, 80%), rgba(var(--m6-b3-c,  13, 63,204), var(--m6-b3-o, 0.10)) 0%, transparent var(--m6-b3-r, 40%)),
        radial-gradient(circle at var(--m6-b4-x, 80%) var(--m6-b4-y, 70%), rgba(var(--m6-b4-c, 126,179,255), var(--m6-b4-o, 0.12)) 0%, transparent var(--m6-b4-r, 35%));
    background-attachment: fixed;
    color: var(--text);
    font-family: var(--font-display);
    line-height: 1.55;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* Two big floating circles drifting behind everything. z-index:-1 keeps them
   behind content; animation-delay staggers them so they never quite align. */
body::before,
body::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
    animation: m6-float 20s ease-in-out infinite;
}
body::before {
    width:  var(--m6-o1-size, 300px);
    height: var(--m6-o1-size, 300px);
    background: linear-gradient(135deg, rgba(26, 92, 255, 0.08), rgba(77, 138, 255, 0.08));
    top: -100px;
    right: -50px;
    animation-delay: var(--m6-o1-delay, -5s);
}
body::after {
    width:  var(--m6-o2-size, 400px);
    height: var(--m6-o2-size, 400px);
    background: linear-gradient(135deg, rgba(13, 63, 204, 0.08), rgba(77, 138, 255, 0.06));
    bottom: -150px;
    left: -100px;
    animation-delay: var(--m6-o2-delay, 0s);
}
@keyframes m6-float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-30px) rotate(5deg); }
}
@media (prefers-reduced-motion: reduce) {
    body::before, body::after { animation: none; }
}
.m6-main { flex: 1 0 auto; }
.m6-foot { margin-top: auto; }
img { max-width: 100%; height: auto; }
a { color: var(--accent); text-decoration: none; }

/* ---- NAV (dark navy, matches mr6.com homepage) ---- */
.m6-nav {
    position: sticky; top: 0; z-index: 50;
    background: linear-gradient(135deg, #0A0F1E 0%, #111B3A 50%, #0D2147 100%);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    box-shadow: 0 4px 16px rgba(10,15,30,0.18);
}
.m6-nav__inner {
    max-width: 1080px; margin: 0 auto;
    padding: 14px 28px;
    display: flex; align-items: center; gap: 18px;
}
.m6-nav__logo { display: inline-flex; align-items: center; margin-right: auto; }
.m6-nav__logo img { display: block; height: 31px; width: auto; }
.m6-nav__links { display: flex; gap: 6px; align-items: center; }
.m6-nav__links a {
    color: rgba(255,255,255,0.72);
    font-weight: 600; font-size: 14px;
    padding: 8px 14px; border-radius: 10px;
    transition: background 0.2s, color 0.2s;
}
.m6-nav__links a:hover { background: rgba(255,255,255,0.08); color: #fff; }
.m6-nav__cta {
    background: linear-gradient(135deg, var(--accent), var(--accent-glow)) !important;
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(26,92,255,0.30);
}
.m6-nav__cta:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(26,92,255,0.40); }

.m6-nav__burger {
    display: none;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 10px; padding: 8px 10px;
    cursor: pointer; align-items: center; justify-content: center;
    gap: 3px; flex-direction: column;
}
.m6-nav__burger span {
    display: block; width: 20px; height: 2px; border-radius: 2px;
    background: #fff;
    transition: transform 0.2s, opacity 0.2s;
}
.m6-nav__burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.m6-nav__burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.m6-nav__burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 720px) {
    .m6-nav__inner { padding: 10px 14px; gap: 10px; }
    .m6-nav__burger { display: inline-flex; }
    .m6-nav__links {
        display: none;
        position: absolute; top: 100%; left: 0; right: 0;
        flex-direction: column; gap: 0;
        background: linear-gradient(180deg, #0D2147 0%, #0A0F1E 100%);
        border-bottom: 1px solid rgba(255,255,255,0.08);
        padding: 10px 14px 14px;
        box-shadow: 0 12px 28px rgba(10,15,30,0.35);
    }
    .m6-nav__links.is-open { display: flex; }
    .m6-nav__links a { padding: 12px 14px; font-size: 15px; }
}

/* ---- HERO ---- */
.m6-hero { padding: 64px 0 24px; }
.m6-hero__inner { max-width: 780px; margin: 0 auto; padding: 0 28px; }
.m6-hero__eyebrow {
    display: inline-block;
    font-family: var(--font-display); font-weight: 700;
    font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase;
    background: linear-gradient(135deg, var(--accent), var(--accent-glow));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 14px;
}
.m6-hero h1 {
    font-family: var(--font-display); font-weight: 700;
    font-size: clamp(30px, 4.4vw, 52px); line-height: 1.08;
    letter-spacing: -0.025em; margin: 0 0 14px;
    color: var(--text);
}
.m6-hero h1 em {
    font-style: italic;
    background: linear-gradient(135deg, var(--accent), var(--accent-glow));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.m6-hero__sub {
    color: var(--muted); font-size: 17px; line-height: 1.6;
    max-width: 620px; margin: 0;
}

/* ---- POST LIST ---- */
.m6-list { padding: 24px 0 96px; }
.m6-list__inner { max-width: 780px; margin: 0 auto; padding: 0 28px; }

.m6-card { margin-bottom: 32px; }
.m6-card__link {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 22px;
    color: inherit; text-decoration: none;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.m6-card__link:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(13,63,204,0.10);
    border-color: rgba(26,92,255,0.35);
}
.m6-card__cover {
    background-size: cover; background-position: center;
    background-color: var(--tag-bg);
    min-height: 140px;
}
.m6-card__body { padding: 18px 22px 18px 4px; }
.m6-card__tag {
    display: inline-block;
    font-size: 10.5px; font-weight: 700;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 8px;
}
.m6-card__title {
    font-family: var(--font-display); font-weight: 700;
    font-size: clamp(19px, 2.2vw, 24px);
    line-height: 1.25; letter-spacing: -0.015em;
    margin: 0 0 8px; color: var(--text);
}
.m6-card__link:hover .m6-card__title { color: var(--accent); }
.m6-card__excerpt {
    color: var(--muted); font-size: 15px; line-height: 1.55;
    margin: 0 0 12px;
}
.m6-card__meta {
    color: var(--muted); font-size: 12.5px;
}
.m6-dot { color: var(--border); }

/* Lead (first) card = hero-style: cover on top, larger title. */
.m6-card--lead .m6-card__link { grid-template-columns: 1fr; }
.m6-card--lead .m6-card__cover { min-height: 260px; }
.m6-card--lead .m6-card__body { padding: 24px 32px 28px; }
.m6-card--lead .m6-card__title { font-size: clamp(24px, 3vw, 34px); }

@media (max-width: 640px) {
    .m6-card__link { grid-template-columns: 1fr; }
    .m6-card__cover { min-height: 180px; }
    .m6-card__body { padding: 18px 22px 22px; }
}

.m6-pager {
    display: flex; gap: 18px; justify-content: center; align-items: center;
    padding: 24px 0 8px;
    color: var(--muted);
}
.m6-pager a {
    color: var(--accent); font-weight: 600;
    padding: 8px 14px; border-radius: 10px;
    border: 1px solid var(--border); background: var(--bg-white);
}
.m6-pager a:hover { background: var(--tag-bg); }

/* ==========================================================
   SINGLE ARTICLE — ATOPAI blog-post layout mimic
   Fonts, spacing, hero image, body typography all copied from
   atopai.org/blog/*. Only the color palette differs — everything
   else is 1:1.
   ========================================================== */
.m6-article { padding: 0 0 6rem; }
.m6-article__inner {
    /* Wider outer column so the hero image can breathe like ATOPAI's
       .col-lg-10 (~950px in a Bootstrap container). Body + header still
       cap at 720px inside this — see the rules below. */
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 16px;
}

/* --- Centered header: meta on top, big serif title, subtitle --- */
.m6-article__header {
    text-align: center;
    padding: 4rem 0 2rem;
    max-width: 720px;
    margin: 0 auto;
}
.m6-article__meta {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--muted);
    letter-spacing: 0.03em;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.m6-article__sep {
    width: 4px;
    height: 4px;
    background: #9ca3af;
    border-radius: 50%;
    display: inline-block;
}
.m6-article__title {
    font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    font-weight: 700;
    font-size: clamp(2.2rem, 5vw, 3.2rem);
    line-height: 1.15;
    letter-spacing: -0.03em;
    color: var(--text);
    margin: 0;
}
.m6-article__subtitle {
    font-family: 'Source Serif 4', Georgia, serif;
    font-weight: 400;
    font-size: 1.35rem;
    color: var(--muted);
    line-height: 1.5;
    margin: 1.25rem 0 0;
    letter-spacing: -0.005em;
}

/* --- Hero (feature image) — fills the wide outer column --- */
.m6-article__hero {
    display: block;
    width: 100%;
    height: auto;
    max-width: 1000px;
    margin: 0 auto 3rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(10, 15, 30, 0.08);
}

/* --- Body typography (Medium-like, Source Serif 4) --- */
.m6-article__body {
    font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    font-size: 1.4rem;              /* ~22.4px — comfortable reading */
    font-weight: 400;
    line-height: 1.85;
    color: var(--text);
    letter-spacing: -0.003em;
    max-width: 720px;
    margin: 0 auto;
}
.m6-article__body p {
    font-family: inherit;
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1.85;
    color: var(--text);
    letter-spacing: -0.003em;
    margin: 0 0 1.35rem;
}
.m6-article__body h1,
.m6-article__body h2,
.m6-article__body h3,
.m6-article__body h4,
.m6-article__body h5,
.m6-article__body h6 {
    font-family: 'Source Serif 4', Georgia, serif;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.02em;
}
.m6-article__body h2 {
    font-size: 1.65rem;
    line-height: 1.25;
    margin: 2.75rem 0 0.75rem;
}
.m6-article__body h3 {
    font-size: 1.35rem;
    line-height: 1.3;
    margin: 2.25rem 0 0.6rem;
}
.m6-article__body h4 {
    font-size: 1.15rem;
    line-height: 1.35;
    margin: 2rem 0 0.5rem;
}
.m6-article__body a {
    color: inherit;
    font-family: inherit;
    font-weight: inherit;
    text-decoration: underline;
    text-decoration-color: rgba(10, 15, 30, 0.35);
    text-underline-offset: 3px;
    transition: text-decoration-color 0.2s ease;
}
.m6-article__body a:hover { text-decoration-color: var(--accent); }

.m6-article__body blockquote {
    border-left: 3px solid var(--text);
    margin: 2.25rem 0 2.25rem -20px;
    padding: 0.15rem 0 0.15rem 1.75rem;
    font-style: italic;
}
.m6-article__body blockquote p {
    font-family: 'Source Serif 4', Georgia, serif;
    font-size: 1.35rem;
    line-height: 1.7;
    color: var(--text);
    margin-bottom: 0.5rem;
}

.m6-article__body pre {
    font-family: 'SFMono-Regular', Menlo, Consolas, monospace;
    background: #282c34;
    color: #abb2bf;
    border-radius: 8px;
    padding: 1.5rem 1.75rem;
    overflow-x: auto;
    margin: 2rem -1rem;
    font-size: 0.9rem;
    line-height: 1.7;
    letter-spacing: 0;
    border: 1px solid rgba(0, 0, 0, 0.08);
}
.m6-article__body code {
    font-family: 'SFMono-Regular', Menlo, Consolas, monospace;
    font-size: 0.88em;
}
.m6-article__body :not(pre) > code {
    background: var(--tag-bg);
    padding: 0.2em 0.45em;
    border-radius: 4px;
    color: var(--accent);
}

.m6-article__body img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2rem 0;
    box-shadow: 0 2px 12px rgba(10, 15, 30, 0.06);
}

.m6-article__body ul,
.m6-article__body ol {
    margin: 0 0 1.35rem;
    padding-left: 1.75rem;
}
.m6-article__body li {
    font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1.85;
    color: var(--text);
    letter-spacing: -0.003em;
    margin-bottom: 0.4rem;
}
.m6-article__body li::marker { color: var(--muted); font-family: 'Source Serif 4', Georgia, serif; font-weight: 400; }
.m6-article__body ol li::marker { font-weight: 600; }

.m6-article__body strong,
.m6-article__body b { font-family: inherit; font-weight: 700; color: var(--text); }
.m6-article__body em,
.m6-article__body i:not([class]) { font-family: inherit; font-style: italic; }

.m6-article__body hr {
    border: none;
    text-align: center;
    margin: 3rem 0;
}
.m6-article__body hr::before {
    content: '...';
    font-family: 'Source Serif 4', Georgia, serif;
    font-size: 1.75rem;
    letter-spacing: 0.6em;
    color: #9ca3af;
}

/* Ghost Koenig cards inside the ATOPAI-styled body */
.m6-article__body figure { margin: 2rem 0; }
.m6-article__body figure img { margin: 0; }
.m6-article__body figcaption {
    margin-top: 0.5rem;
    font-family: 'Poppins', sans-serif;
    font-size: 0.85rem;
    color: var(--muted);
    text-align: center;
}
.m6-article__body .kg-width-wide { margin-left: -40px; margin-right: -40px; max-width: none; }
.m6-article__body .kg-width-full { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); max-width: 100vw; }
.m6-article__body .kg-bookmark-card,
.m6-article__body .kg-embed-card,
.m6-article__body .kg-callout-card,
.m6-article__body .kg-toggle-card { margin: 2rem 0; }
.m6-article__body .kg-bookmark-container {
    display: flex; border: 1px solid var(--border); border-radius: 12px;
    overflow: hidden; text-decoration: none; color: var(--text);
    background: var(--bg-white);
    transition: box-shadow 0.2s, border-color 0.2s;
}
.m6-article__body .kg-bookmark-container:hover {
    border-color: rgba(26,92,255,0.35);
    box-shadow: 0 8px 24px rgba(13,63,204,0.10);
}
.m6-article__body .kg-bookmark-content { padding: 18px 22px; flex: 1; font-family: 'Poppins', sans-serif; }
.m6-article__body .kg-bookmark-title { font-weight: 700; margin-bottom: 6px; font-size: 1rem; }
.m6-article__body .kg-bookmark-description { color: var(--muted); font-size: 0.9rem; }
.m6-article__body .kg-callout-card {
    padding: 18px 22px; border-radius: 12px;
    background: var(--tag-bg); color: var(--text);
}

/* Subscribe CTA on posts */
.m6-subscribe {
    margin: 48px auto 0;
    max-width: 640px;
    padding: 28px;
    background: linear-gradient(135deg, var(--bg-white) 0%, #EEF3FC 100%);
    border: 1px solid var(--border);
    border-radius: 14px;
    text-align: center;
}
.m6-subscribe h3 {
    font-family: var(--font-display); font-weight: 700; font-size: 22px;
    margin: 0 0 8px; letter-spacing: -0.01em;
}
.m6-subscribe p { color: var(--muted); margin: 0 0 16px; font-family: var(--font-display); }

.m6-article__foot {
    display: flex; gap: 14px; flex-wrap: wrap;
    margin: 48px auto 0; padding-top: 28px;
    border-top: 1px solid var(--border);
    max-width: 640px;
}

.m6-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 11px 20px; border-radius: 10px;
    font-family: var(--font-display); font-weight: 600; font-size: 14.5px;
    cursor: pointer; border: none;
    transition: transform 0.2s, box-shadow 0.2s;
}
.m6-btn--primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-glow));
    color: #fff; box-shadow: 0 6px 18px rgba(26,92,255,0.28);
}
.m6-btn--primary:hover { transform: translateY(-1px); box-shadow: 0 10px 24px rgba(26,92,255,0.38); }
.m6-btn--ghost {
    background: var(--bg-white); color: var(--accent);
    border: 1px solid var(--accent);
}
.m6-btn--ghost:hover { background: var(--tag-bg); }

/* ---- FOOTER ---- */
.m6-foot {
    border-top: 1px solid var(--border);
    background: var(--bg-white);
    padding: 24px 0; margin-top: 64px;
}
.m6-foot__inner {
    max-width: 1080px; margin: 0 auto; padding: 0 28px;
    display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap;
    font-size: 13px; color: var(--muted);
}
.m6-foot a { color: var(--accent); }

/* ============================================================
   MOBILE PASS — everything below 640px
   ============================================================ */
@media (max-width: 640px) {
    /* Tighter container padding across the board. */
    .m6-hero__inner,
    .m6-list__inner,
    .m6-article__inner,
    .m6-foot__inner { padding-left: 14px; padding-right: 14px; }

    /* Hero — tighter top spacing on small screens. */
    .m6-hero { padding: 40px 0 20px; }
    .m6-hero__sub { font-size: 16px; }

    /* Article body — tighten margins, keep the ATOPAI serif rhythm. */
    .m6-article { padding: 0 0 4rem; }
    .m6-article__header { padding: 2.5rem 0 1.25rem; }
    .m6-article__meta { gap: 0.5rem; margin-bottom: 1rem; font-size: 0.8rem; }
    .m6-article__hero { border-radius: 10px; margin-bottom: 2rem; }
    /* On mobile, match subtitle to body paragraph — the 1.35rem desktop size
       reads as shouty on a narrow screen. */
    .m6-article__subtitle { font-size: 1.15rem; line-height: 1.55; margin-top: 1rem; }
    .m6-article__body { font-size: 1.15rem; line-height: 1.75; }
    .m6-article__body p,
    .m6-article__body li { font-size: 1.15rem; line-height: 1.75; }
    .m6-article__body h2 { font-size: 1.4rem; margin-top: 2rem; }
    .m6-article__body h3 { font-size: 1.2rem; margin-top: 1.75rem; }
    .m6-article__body h4 { font-size: 1.05rem; margin-top: 1.5rem; }
    .m6-article__body pre { padding: 1rem; font-size: 0.82rem; border-radius: 6px; margin-left: -0.5rem; margin-right: -0.5rem; }
    .m6-article__body blockquote { margin-left: 0; padding-left: 1rem; }
    .m6-article__body blockquote p { font-size: 1.1rem; }
    .m6-article__body .kg-width-wide { margin-left: 0; margin-right: 0; }
    .m6-article__body img { margin: 1.5rem 0; }

    /* Ghost Koenig wide/full cards — let big media reach edge-to-edge. */
    .m6-article__body .kg-width-full img { border-radius: 0; }

    /* Article-foot buttons stack full-width instead of side-by-side. */
    .m6-article__foot { flex-direction: column; align-items: stretch; padding-top: 20px; }
    .m6-article__foot .m6-btn { justify-content: center; }

    /* Subscribe CTA sits tighter. */
    .m6-subscribe { padding: 22px 20px; margin-top: 36px; }
    .m6-subscribe h3 { font-size: 20px; }

    /* Footer stacks vertically. */
    .m6-foot__inner { flex-direction: column; gap: 6px; align-items: flex-start; }
    .m6-foot { padding: 20px 0; margin-top: 40px; }

    /* List cards already collapse to single-column at 640 (rule earlier);
       just tighten spacing. */
    .m6-card { margin-bottom: 24px; }
    .m6-card--lead .m6-card__cover { min-height: 200px; }
    .m6-card--lead .m6-card__body { padding: 20px 22px 24px; }
    .m6-card__body { padding: 16px 20px 20px; }
}

@media (max-width: 420px) {
    .m6-hero__inner,
    .m6-list__inner,
    .m6-article__inner { padding-left: 10px; padding-right: 10px; }
    .m6-article__title { font-size: 28px; }
    .m6-hero h1 { font-size: 28px; }
}

/* ─── Related posts (post.hbs) ─── */
.m6-related {
    max-width: 1120px;
    margin: 48px auto 32px;
    padding: 32px 32px 0;
    border-top: 1px solid rgba(10,15,30,0.08);
}
.m6-related__head {
    text-align: center;
    margin-bottom: 28px;
    padding-top: 32px;
    border-top: 1px solid rgba(10,15,30,0.08);
}
.m6-related__eyebrow {
    display: inline-block;
    font-family: 'Space Grotesk', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--accent, #1A5CFF);
    margin-bottom: 8px;
}
.m6-related__title {
    font-family: 'Source Serif 4', Georgia, serif;
    font-size: 28px;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 0;
}
.m6-related__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
/* Related cards: never promote one to "lead" size — always 3 uniform tiles. */
/* Force ALL cards in the related grid to top-image layout (override the
   default 160px-side layout used on index.hbs). Related tiles must look
   uniform — the "lead" designation is index-only. */
.m6-related__grid .m6-card { margin-bottom: 0; }
.m6-related__grid .m6-card__link {
    display: flex;
    flex-direction: column;
    grid-template-columns: 1fr;   /* neutralize grid if it wins the cascade */
    gap: 0;
}
.m6-related__grid .m6-card__cover {
    width: 100%;
    min-height: 160px;
    background-size: cover;
    background-position: center;
}
.m6-related__grid .m6-card__body { padding: 16px 20px 20px; }
.m6-related__grid .m6-card__title { font-size: 20px; }
/* Hide author / date / reading time on related tiles per site owner request. */
.m6-related__grid .m6-card__meta { display: none; }
@media (max-width: 900px) {
    .m6-related__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .m6-related { padding: 0 20px; margin-top: 48px; }
    .m6-related__grid { grid-template-columns: 1fr; }
    .m6-related__title { font-size: 24px; }
}
