    :root{
            --rule: rgba(17,17,17,.18);
      --measure-narrow: 660px;
--bg: #F5F5F3;
      --ink: #111111;
      --muted: #5A5A5A;
      --line: rgba(17,17,17,.12);
      --chip: rgba(17,17,17,.06);
      --max: 1080px;
      --measure: 720px;
      --btn-border: rgba(17,17,17,.55);
      --btn-hover: rgba(17,17,17,.03);

    }

    

    html[data-theme="dark"],
    [data-theme="dark"]{
      --bg: #0F0F10;
      --ink: #F2F2F2;
      --muted: rgba(242,242,242,.70);
      --line: rgba(242,242,242,.14);
      --rule: rgba(242,242,242,.18);
      --chip: rgba(242,242,242,.08);
      --btn-border: rgba(242,242,242,.55);
      --btn-hover: rgba(242,242,242,.06);
    }
*{ box-sizing:border-box; }
    html,body{ height:100%; }
    body{
      margin:0;
      font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
      background: var(--bg);
      color: var(--ink);
      -webkit-font-smoothing: antialiased;
      text-rendering: optimizeLegibility;
    }

    a{ color: inherit; text-decoration: none; }
    a:hover{ text-decoration: underline; text-underline-offset: 3px; }
    /* Never underline the stacked wordmark */
    .brand, .brand:hover, .brand:focus{ text-decoration: none !important; }

    .wrap{
      max-width: var(--max);
      margin: 0 auto;
      padding: 28px 22px 80px;
      min-height: 100%;
      display:flex;
      flex-direction: column;
    }

    header{
      display:flex;
      align-items:flex-start;
      justify-content:space-between;
      gap: 18px;
      padding-top: 8px;
    }

    .brand{
      line-height: .95;
      letter-spacing: .08em;
      user-select:none;
    }
    .brand .cap,
    .brand .risk{
      font-weight:700;
      font-size: 28px;
    }
    .brand .at{
      font-weight:400;
      font-size: 20px;
      margin: 6px 0;
    }

    .nav{
      display:flex;
      gap: 14px;
      align-items:center;
      color: var(--muted);
      font-size: 14px;
    }

    .btn{
      padding: 10px 12px;
      border: 1px solid var(--btn-border);
      border-radius: 999px;
      font-size: 14px;
      font-weight: 500;
      background: transparent;
      cursor:pointer;
    
      color: var(--ink);
}
    .btn:hover{ background: var(--btn-hover); text-decoration:none; }

    /* Force consistent rounded controls everywhere (native buttons + Koenig buttons) */
    button,
    input[type="submit"],
    input[type="button"],
    input[type="reset"],
    .kg-button-card a.kg-btn,
    .kg-button-card a.kg-btn-accent,
    .kg-button-card a.kg-btn-default,
    .gh-btn,
    .gh-head-button{
      border-radius: 999px !important;
    }

    /*
      Keep `main` as a normal block flow container.
      Previously this was `display:flex`, which caused the homepage hero and
      the "Latest" section to render side-by-side (unwanted two-column layout)
      and contributed to spacing inconsistencies across templates.
    */
    main{
      flex: 1;
      display:block;
      padding-top: 72px;
    }

    /* Homepage: a touch more air, but not vertically centred */
    body.home-template main{ padding-top: 96px; }

    .hero{
      max-width: var(--measure);
      padding: 64px 0 24px;
    }

    h1{
      margin:0 0 12px;
      font-size: clamp(40px, 4.2vw, 52px);
      letter-spacing: -0.03em;
      line-height: 1.08;
      font-weight: 600;
    }

    .sub{
      margin:0;
      color: var(--muted);
      font-size: 18px;
      line-height: 1.55;
      max-width: 70ch;
    }

    .pillrow{
      margin-top: 18px;
      display:flex;
      flex-wrap:wrap;
      gap: 10px;
      align-items:center;
    }

    .chip{
      display:inline-flex;
      align-items:center;
      gap: 8px;
      padding: 8px 10px;
      border: 1px solid var(--line);
      border-radius: 999px;
      background: rgba(255,255,255,.40);
      color: var(--muted);
      font-size: 13px;
      letter-spacing: .01em;
    }

    .divider{
      margin: 36px 0 18px;
      border-top: 1px solid var(--line);
      border-left: none;
      border-right: none;
      border-bottom: none;
      max-width: var(--measure);
    }

    footer{
      padding-top: 18px;
      border-top: 1px solid var(--line);
      color: var(--muted);
      font-size: 12.5px;
      max-width: var(--measure);
    }

    @media (max-width: 640px){
      .nav a{ color: var(--muted);
      display:none; }
      .hero{ padding-top: 44px; }
    }
  
/* Default to system dark mode when no explicit theme is set */
@media (prefers-color-scheme: dark){
  html:not([data-theme]){
    --bg: #0F0F10;
    --ink: #F2F2F2;
    --muted: rgba(242,242,242,.70);
    --line: rgba(242,242,242,.14);
      --rule: rgba(242,242,242,.18);
    --chip: rgba(242,242,242,.08);
    --btn-border: rgba(242,242,242,.55);
    --btn-hover: rgba(242,242,242,.06);
    }
}

/* --- Ghost Koenig editor support --- */
.gh-content { width: 100%; }
.gh-content img, .gh-content video { max-width: 100%; height: auto; }

.kg-width-wide { max-width: 1040px; margin-left: auto; margin-right: auto; }
.kg-width-full {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
.kg-width-full img, .kg-width-full video { width: 100%; height: auto; }


/* --- Homepage latest posts --- */
.latest{
  margin-top: 22px;
}
.latest-title{
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .02em;
  color: var(--muted);
  margin: 0 0 10px 0;
}
.postlist{
  display: grid;
  gap: 10px;
}
.postitem{
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  background: transparent; /* remove grey fill */
}
.postlink{
  display: block;
  text-decoration: none;
  color: var(--ink);
}
.postmeta{
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}
.posttitle{
  margin: 0 0 6px 0;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.postexcerpt{
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}
.postitem:hover{
  background: rgba(17,17,17,.03);
}


/* --- Post template (faithful) --- */
.rule{
  margin: 26px 0 30px;
  border:0;
  border-top: 1px solid var(--rule);
}

.post{
  max-width: var(--measure);
}

.kicker{
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-weight: 600;
  margin: 0 0 14px;
  color: var(--muted);
}

.post h1{
  margin:0 0 12px;
  font-size: clamp(34px, 3.6vw, 46px);
  line-height: 1.08;
  letter-spacing: -0.04em;
  font-weight: 600;
}

.meta{
  display:flex;
  flex-wrap:wrap;
  gap: 10px 14px;
  align-items:baseline;
  margin: 10px 0 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
  letter-spacing: .01em;
}
.meta strong{ color: var(--ink); font-weight: 600; }
.dot::before{ content: "·"; margin-right: 14px; color: var(--muted); }

.actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items:center;
  margin: 18px 0 8px;
  color: var(--muted);
  font-size: 13px;
}
.actions .hint{ color: var(--muted); }

.abstract{
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 16px 0;
  margin: 18px 0 26px;
  max-width: var(--measure-narrow);
}
.abstract h2{
  margin:0 0 8px;
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--muted);
}
.abstract p{
  margin:0;
  font-size: 15.5px;
  line-height: 1.7;
  color: var(--ink);
}

.content{
  max-width: var(--measure-narrow);
  font-size: 15.5px;
  line-height: 1.78;
  letter-spacing: .005em;
}
.content p{ margin: 0 0 16px; color: var(--ink); }
.content h2{
  margin: 34px 0 10px;
  font-size: 16px;
  line-height: 1.35;
  letter-spacing: .02em;
  font-weight: 600;
}
.content h3{
  margin: 26px 0 8px;
  font-size: 14px;
  line-height: 1.4;
  letter-spacing: .02em;
  font-weight: 600;
  color: var(--ink);
}

.content blockquote{
  margin: 22px 0;
  padding: 0 0 0 16px;
  border-left: 2px solid var(--btn-border);
  color: var(--ink);
}
.content blockquote p{ margin: 0; }

.content ul{ margin: 0 0 18px 18px; padding: 0; }
.content li{ margin: 6px 0; }

.post-footer{
  margin-top: 62px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
  max-width: var(--measure);
}
.post-disclaimer{ margin-top: 10px; }

@media (max-width: 640px){
  .abstract, .content{ max-width: 100%; }
}

@media print{
  .nav, .actions, .theme-toggle{ display:none !important; }
  .wrap{ padding: 0; }
  a{ text-decoration:none; }
}


/* Post/page: keep shared system */

/* --- Scope fix: prevent homepage layout rules affecting posts/pages --- */
.post-template main,
.page-template main{
  display: block !important;
  min-height: auto !important;
  height: auto !important;
}

.post-template .wrap,
.page-template .wrap{
  display: block !important;
}

.post-template .hero,
.page-template .hero{
  all: unset;
  display: block;
}

/* Ensure post container aligns left within wrap like the original template */
.post-template .post,
.page-template .post{
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* Content blocks should not be constrained by any grid centering rules */
.post-template .post,
.post-template .abstract,
.post-template .content,
.page-template .post,
.page-template .content{
  justify-self: start !important;
  align-self: start !important;
}

/* In case global rules center everything */
.post-template body,
.page-template body{
  place-items: unset !important;
}


/* --- Logo link fix --- */
.brand{ text-decoration: none !important; }
.brand:hover,.brand:focus,.brand:active{ text-decoration: none !important; }


/* --- Koenig (Ghost editor) minimal styling pack --- */

/* Base media */
.gh-content img,
.gh-content video{
  max-width: 100%;
  height: auto;
  display: block;
}

/* Captions */
.gh-content figcaption{
  margin-top: 8px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
}

/* Image card */
.kg-image-card{
  margin: 22px 0;
}

/* Gallery */
.kg-gallery-card{
  margin: 22px 0;
}
.kg-gallery-container{
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.kg-gallery-row{
  display: flex;
  gap: 12px;
}
.kg-gallery-image img{
  width: 100%;
  height: auto;
}

/* Embed / video */
.kg-embed-card,
.kg-video-card{
  margin: 26px 0;
}
.kg-embed-card iframe,
.kg-video-card iframe,
.kg-video-card video{
  width: 100%;
}

/* Bookmark (link preview) */
.kg-bookmark-card{
  margin: 26px 0;
}
.kg-bookmark-container{
  display: grid;
  grid-template-columns: 1fr;
  border: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
}
.kg-bookmark-content{
  padding: 14px 16px;
}
.kg-bookmark-title{
  font-weight: 600;
  margin: 0 0 6px 0;
}
.kg-bookmark-description{
  margin: 0 0 10px 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}
.kg-bookmark-metadata{
  display:flex;
  gap: 10px;
  align-items:center;
  color: var(--muted);
  font-size: 12.5px;
}
.kg-bookmark-thumbnail img{
  display:block;
  width: 100%;
  height: auto;
  border-top: 1px solid var(--line);
}

/* Callout */
.kg-callout-card{
  margin: 26px 0;
  border-left: 2px solid var(--btn-border);
  padding: 10px 0 10px 16px;
}
.kg-callout-text{
  color: var(--ink);
  line-height: 1.7;
}
.kg-callout-emoji{
  margin-right: 10px;
}

/* Toggle */
.kg-toggle-card{
  margin: 22px 0;
  border: 1px solid var(--line);
}
.kg-toggle-heading{
  padding: 12px 14px;
  cursor: pointer;
  font-weight: 600;
}
.kg-toggle-content{
  padding: 0 14px 14px;
  color: var(--ink);
}
.kg-toggle-card summary{
  list-style: none;
}
.kg-toggle-card summary::-webkit-details-marker{
  display:none;
}

/* Buttons created in editor */
.kg-button-card{
  margin: 22px 0;
}
.kg-button-card a.kg-btn{
  display: inline-block;
  padding: 10px 14px;
  border: 1px solid var(--btn-border);
  background: transparent;
  color: var(--ink);
  text-decoration: none;
}
.kg-button-card a.kg-btn:hover{
  background: var(--btn-hover);
}

/* Divider */
.kg-divider-card{
  margin: 28px 0;
}
.kg-divider-card hr{
  border: 0;
  border-top: 1px solid var(--line);
}

/* Code */
.gh-content pre{
  overflow: auto;
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 13px;
  line-height: 1.6;
}
.gh-content code{
  font-size: 0.95em;
}


/* --- Post feature image --- */
.post-feature{
  margin: 18px 0 10px;
}
.post-feature img{
  width: 100%;
  height: auto;
  display: block;
}


/* --- Footer spacing adjustment --- */
.post-footer{
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.post-footer .back-btn{
  align-self: flex-start;
}


/* --- Mockup alignment tweaks --- */
.abstract h2{
  text-transform: uppercase !important;
  letter-spacing: .18em !important;
}

.actions{
  gap: 10px;
}

.actions .btn{
  padding: 8px 12px;
  font-size: 13px;
}

.actions .hint{
  margin-left: 4px;
}

/* Slightly tighter title + meta rhythm like the mockup */
.post h1{
  margin-bottom: 10px;
}
.meta{
  margin-top: 6px;
}


/* --- Footnotes sizing --- */
.content h2#footnotes,
.content h2.footnotes,
.content h2:has(+ ol){
  /* keep existing h2 styling */
}

.content ol{
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--muted);
}

.content ol li{
  margin: 6px 0;
}

.content ol a{
  color: inherit;
}


/* --- Post footer text --- */
.post-footer{
  margin-top: 62px;
  padding-top: 18px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
  max-width: var(--measure);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.post-copyright{
  color: var(--muted);
}


/* --- Button consistency --- */
.btn{
  border-radius: 6px;
}


/* --- Unified site footer --- */
.site-footer{
  margin-top: 64px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.6;
}
.site-footer-inner{
  max-width: var(--measure);
}

/* --- Research page --- */
.research{
  padding-top: 36px;
  padding-bottom: 16px;
  max-width: var(--measure);
}
.research-title{
  margin: 0 0 10px 0;
  font-size: clamp(28px, 3vw, 38px);
  letter-spacing: -0.03em;
}
.research-sub{
  margin: 0 0 18px 0;
  color: var(--muted);
  max-width: 62ch;
}
.research-list{
  display: grid;
  gap: 12px;
  margin-top: 18px;
}
.research-item{
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.research-link{
  text-decoration: none;
  color: inherit;
  display: block;
}
.research-meta{
  color: var(--muted);
  font-size: 12.5px;
  display:flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
}
.research-item-title{
  margin: 6px 0 6px 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.research-excerpt{
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  max-width: 72ch;
}



/* --- Pagination --- */
.pagination{
  display: flex;
  gap: 10px;
  margin-top: 22px;
}

/* --- Brand Guidelines: Inter --- */
body{
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
}



/* --- Page width alignment --- */
.page-template .content{
  max-width: var(--measure) !important;
}


/* --- Global typography & layout (authoritative) --- */
:root{
  --wrap-max: 1120px;
  --measure: 720px;
  --measure-narrow: 660px;
  --bg: #F5F5F3;
  --ink: #1A1A1A;
  --muted: #4D4D4D;
  --line: rgba(17,17,17,.14);
  --rule: rgba(17,17,17,.18);
  --btn-border: rgba(17,17,17,.55);
  --btn-hover: rgba(17,17,17,.04);
}

html[data-theme="dark"]{
  --bg: #0b0c0f;
  --ink: #f2f2f2;
  --muted: rgba(242,242,242,.70);
  --line: rgba(242,242,242,.14);
  --rule: rgba(242,242,242,.18);
  --btn-border: rgba(242,242,242,.55);
  --btn-hover: rgba(242,242,242,.06);
}

body{
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

/* Wrap should be identical on every template */
.wrap{
  max-width: var(--wrap-max);
  margin-left: auto;
  margin-right: auto;
}

/* Nav sizing consistent everywhere */
.nav{
  font-size: 13px;
  letter-spacing: .02em;
  color: var(--muted);
}
.nav a{ color: var(--muted); }

/* Logo system (exact) */
.brand{
  text-decoration:none !important;
  user-select:none;
  line-height: .95;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
.brand:hover,.brand:focus,.brand:active{ text-decoration:none !important; }

.brand .cap{
  font-size: 28px;
  font-weight: 700;
  letter-spacing: .08em;
}
.brand .at{
  font-size: 20px;
  font-weight: 600;
  letter-spacing: .10em;
  margin: 6px 0;
}
.brand .risk{
  font-size: 28px;
  font-weight: 800;
  letter-spacing: .08em;
}

/* Titles consistent */
.hero h1,
.post h1,
.page-template h1,
.research-title{
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 600;
  letter-spacing: -0.04em;
}
.hero h1{ font-size: clamp(38px, 5vw, 64px); line-height: 1.02; }
.post h1, .page-template h1{ font-size: clamp(34px, 3.6vw, 46px); line-height: 1.08; }

/* Button corners consistent (rounded like post page earlier) */
.btn{
  border-radius: 6px;
}

/* Content measure consistent across templates */
.hero,
.post,
.research,
.page-template .content,
.post-template .content{
  max-width: var(--measure);
}

/* Remove any leftover template-specific nav overrides */
.post-template .nav,
.page-template .nav{
  font-size: inherit;
}

/* Pagination */
.pagination{ margin-top: 18px; display:flex; gap: 10px; align-items:center; color: var(--muted); font-size: 14px; }
.pagination a{ padding: 8px 10px; border: 1px solid var(--btn-border); border-radius: 999px; text-decoration:none; }
.pagination a:hover{ background: var(--btn-hover); }


/* ===== Authority overrides (do not edit above) ===== */
html{ overflow-y: scroll; } /* prevents width shift between short/long pages */
body{ overflow-x: hidden; }

:root{
  --wrap-max: 1080px;
  --wrap-pad-x: 22px;
  --wrap-pad-top: 28px;
  --wrap-pad-bottom: 80px;

  --measure: 720px;
  --measure-narrow: 660px;
}

/* Layout: enforce identical container geometry on every template */
.wrap{
  max-width: var(--wrap-max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: var(--wrap-pad-top) var(--wrap-pad-x) var(--wrap-pad-bottom) !important;
  min-height: 100% !important;
  display: flex !important;
  flex-direction: column !important;
}

/* Header/nav: stop per-template shrink */
header{
  display:flex !important;
  align-items:flex-start !important;
  justify-content:space-between !important;
  gap: 18px !important;
  padding-top: 8px !important;
}
.nav, nav[aria-label="Primary"]{
  display:flex !important;
  gap: 14px !important;
  align-items:center !important;
  white-space: nowrap !important;
  font-size: 14px !important;
  letter-spacing: .02em !important;
}

/* Brand lockup: Inter per guidelines; keep consistent everywhere */
.brand, .brand *{
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}
.brand{
  line-height: .95 !important;
  letter-spacing: .085em !important;
  user-select:none;
  text-decoration: none !important;
}
.brand:hover, .brand:active, .brand:focus{
  text-decoration: none !important;
}
.brand .cap, .brand .risk{
  font-weight: 600 !important;
  font-size: 28px !important;
}
.brand .at{
  font-weight: 400 !important;
  font-size: 20px !important;
  margin: 6px 0 !important;
  opacity: .95 !important;
}

/* Titles: keep consistent rhythm across home/page/post */
h1{
  font-weight: 600 !important;
  letter-spacing: -0.03em !important;
}
.post-template h1, .page-template h1{
  font-size: clamp(34px, 4vw, 52px) !important;
  line-height: 1.08 !important;
}

/* Buttons: enforce one style everywhere */
.btn, button.btn, a.btn{
  border-radius: 999px !important;
  font-size: 14px !important;
  font-weight: 500 !important;
}

/* Content widths */
.hero, .post, .page, .research, .content{
  max-width: var(--measure) !important;
}
.content, .post .content, .page .content{
  max-width: var(--measure-narrow) !important;
}

/* ===== End overrides ===== */

/* =========================================================
   Authority block: lock layout + header sizes everywhere
   (Keep this at end of file)
   ========================================================= */

html{ overflow-y: scroll; } /* prevents layout shift */

/* Global widths */
:root{
  --max: 1080px;
  --measure: 720px;
}

.wrap{
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

/* Post/page/main column consistency */
main.post,
main.page,
main.research,
main{
  width: 100%;
}

body.post-template main.post{
  max-width: var(--measure);
}

body.page-template main.page,
body.page-template main{
  max-width: var(--measure);
}

/* Ensure title/meta/actions follow the same measure */
body.post-template h1,
body.post-template .meta,
body.post-template .actions,
body.post-template .kicker,
body.post-template .content{
  max-width: var(--measure);
}

body.post-template .rule{
  max-width: var(--measure);
}

/* Header calibration (match your second screenshot) */
header .brand{
  line-height: .95;
  letter-spacing: .065em;
}
header .brand .cap,
header .brand .risk{
  font-weight: 600;
  font-size: 24px;
}
header .brand .at{
  font-weight: 400;
  font-size: 17px;
  margin: 4px 0;
  opacity: .95;
}

header .nav{
  font-size: 14px;
  font-weight: 500;
  gap: 18px;
}

.brand, .brand:hover, .brand:focus, .brand:active{
  text-decoration: none !important;
}

/* Rounded buttons everywhere */
.btn,
button.btn,
a.btn,
.kg-button-card a.kg-btn,
.gh-btn{
  border-radius: 999px !important;
}

/* --- Ultra-specific locks (fix /test-2/ header/width drift) --- */
body.home-template .wrap,
body.post-template .wrap,
body.page-template .wrap,
body.tag-template .wrap,
body.author-template .wrap{
  max-width: var(--max) !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 22px !important;
  padding-right: 22px !important;
}

body.post-template header,
body.page-template header,
body.home-template header{
  width: 100% !important;
}

body.post-template header .nav,
body.page-template header .nav,
body.home-template header .nav{
  font-size: 14px !important;
  line-height: 1.2 !important;
  transform: none !important;
}

body.post-template header .nav a,
body.post-template header .nav button,
body.page-template header .nav a,
body.page-template header .nav button{
  font-size: 14px !important;
}

/* Keep the post column and the rule consistent with each other */
body.post-template main.post{
  max-width: var(--measure) !important;
  width: 100% !important;
}
body.post-template .rule{
  max-width: var(--measure) !important;
  width: 100% !important;
}

/* --- Prevent one-off width drift caused by Koenig wide/full cards or media overflow --- */
html{ overflow-y: scroll; }
body{ overflow-x: clip; }

/* Koenig "wide" / "full" cards can force the page wider on a single post */
.gh-content .kg-width-wide,
.gh-content .kg-width-full{
  width: 100% !important;
  max-width: var(--max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

img, video, iframe, embed, object{ max-width: 100%; height: auto; }
pre, code{ max-width: 100%; }
table{ max-width: 100%; display:block; overflow-x:auto; }

/* Feature image sits below actions and should not participate in meta flex */
.post-feature{ margin: 18px 0 0; max-width: var(--measure); }
.post-feature img{ display:block; width:100%; border-radius: 18px; }
.post-feature figcaption{ margin-top: 8px; color: var(--muted); font-size: 12.5px; line-height: 1.45; }

/* Home headline slightly smaller (closer to original concept) */
body.home-template .hero h1{ font-size: clamp(26px, 2.6vw, 36px) !important; line-height: 1.08; }

/* =====================================================================
   FINAL LAYOUT OVERRIDES (single source of truth)
   - Fixes page-to-page width inconsistencies (Home vs Post/About/Research)
   - Restores consistent wrap padding so the page doesn't feel "wider" on Home
   - Gives every template the same top spacing as Home
   - Keeps Home hero readable, while allowing Home lists/cards to use full width
   ===================================================================== */

:root{
  --max: 1080px;
  --measure: 720px;
  --pad-x: 22px;
  --pad-top: 28px;
  --pad-bot: 80px;
}

/* Prevent width "jump" from scrollbars */
html{ overflow-y: scroll; }

/* One outer container on every template */
.wrap{
  width: 100% !important;
  max-width: var(--max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: var(--pad-top) var(--pad-x) var(--pad-bot) !important;
}

/* Same top spacing as Home for ALL pages */
main{ padding-top: 96px !important; }

/* Readable text measure everywhere by default */
.hero,
.post,
.page,
.research{
  max-width: var(--measure) !important;
}

/* Home: keep hero readable but allow the "Latest" list to span the full wrap */
body.home-template .hero{ max-width: var(--measure) !important; }
body.home-template .postlist,
body.home-template .latest,
body.home-template .home-latest{
  max-width: var(--max) !important;
}

/* Card styling: remove heavy grey containers (return to light paper tint) */
.postlist-item,
.card{
  background: rgba(255,255,255,.25) !important;
}

/* Guard against accidental horizontal overflow widening the page */
body{ overflow-x: clip; }

/* Mobile: keep padding sensible */
@media (max-width: 520px){
  .wrap{ padding: 22px 16px 64px !important; }
  main{ padding-top: 72px !important; }
}
