:root{
  --ground:#F2F5F4; --surface:#FFFFFF; --ink:#1C2B2D; --muted:#566769; --line:#D7E0DE;
  --accent:#B23A5B; --accent-ink:#FFFFFF; --accent-soft:#F6E4EA; --sage:#6F8E80; --sage-soft:#E3ECE8;
  --todo:#9A6B00; --todo-bg:#FFF6DC; --logo-filter:none;
  --display:"Bricolage Grotesque", "Trebuchet MS", system-ui, sans-serif;
  --body:"Figtree", "Segoe UI", system-ui, sans-serif;
  --mono:"IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --wrap:920px;
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    color-scheme:dark;
    --ground:#111A1C; --surface:#182528; --ink:#E6EEEC; --muted:#9DB0AE; --line:#2A3B3E;
    --accent:#E0789A; --accent-ink:#1A0E13; --accent-soft:#3A2029; --sage:#8FB3A3; --sage-soft:#1F302B;
    --todo:#F2C35B; --todo-bg:#2E2610; --logo-filter:invert(1) brightness(1.1);
  }
}
:root[data-theme="dark"]{
  color-scheme:dark;
  --ground:#111A1C; --surface:#182528; --ink:#E6EEEC; --muted:#9DB0AE; --line:#2A3B3E;
  --accent:#E0789A; --accent-ink:#1A0E13; --accent-soft:#3A2029; --sage:#8FB3A3; --sage-soft:#1F302B;
  --todo:#F2C35B; --todo-bg:#2E2610; --logo-filter:invert(1) brightness(1.1);
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
@media (prefers-reduced-motion: reduce){html{scroll-behavior:auto}*{transition:none!important}}
body{margin:0;background:var(--ground);color:var(--ink);font:16px/1.6 var(--body);padding-inline:16px}
img{display:block;max-width:100%}
.wrap{max-width:var(--wrap);margin-inline:auto}
h1,h2,h3{font-family:var(--display);font-weight:700;line-height:1.15;text-wrap:balance;margin:0;letter-spacing:-.01em}
p{margin:0}
a{color:inherit}
a:focus-visible,button:focus-visible{outline:3px solid var(--accent);outline-offset:3px;border-radius:6px}
.eyebrow{font:500 .78rem/1.2 var(--mono);text-transform:uppercase;letter-spacing:.08em;color:var(--sage)}
.btn{display:inline-flex;align-items:center;gap:.5rem;padding:.8rem 1.3rem;border-radius:999px;font:600 1rem/1 var(--body);text-decoration:none;border:1.5px solid transparent;cursor:pointer}
.btn-primary{background:var(--accent);color:var(--accent-ink)}
.btn-ghost{border-color:var(--ink);color:var(--ink);background:transparent}

header.top{position:sticky;top:0;z-index:10;background:color-mix(in srgb, var(--ground) 88%, transparent);backdrop-filter:blur(8px);border-bottom:1px solid var(--line);margin-inline:-16px;padding:.75rem 16px}
header.top .wrap{display:flex;align-items:center;justify-content:space-between;gap:1rem;max-width:1120px}
.logo{display:block;flex:none}
.logo img{height:36px;width:auto;filter:var(--logo-filter)}
@media (max-width:420px){.logo img{height:28px}}

.crumbs{display:flex;flex-wrap:wrap;gap:.4rem;font:400 .85rem/1.4 var(--mono);color:var(--muted);margin-block:1.4rem 0}
.crumbs a{text-decoration:none;color:var(--muted)}
.crumbs a:hover{color:var(--ink)}
.crumbs span{opacity:.6}

/* ---- Blog index ---- */
.blog-head{margin-block:1.4rem 2rem;max-width:62ch}
.blog-head h1{font-size:clamp(2rem,5vw,2.6rem);margin-bottom:.6rem}
.blog-head p{color:var(--muted);font-size:1.05rem}

.post-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,280px),1fr));gap:1.3rem;margin-block:0 3rem}
.post-card{display:flex;flex-direction:column;background:var(--surface);border:1px solid var(--line);border-radius:18px;overflow:hidden;text-decoration:none;color:var(--ink)}
.post-card:hover{border-color:var(--accent)}
.post-card .thumb{aspect-ratio:4/3;overflow:hidden;background:var(--sage-soft)}
.post-card .thumb img{width:100%;height:100%;object-fit:cover}
.post-card .body{padding:1.1rem 1.2rem 1.3rem;display:flex;flex-direction:column;gap:.5rem;flex:1}
.post-card time{font:500 .78rem/1 var(--mono);color:var(--sage);text-transform:uppercase;letter-spacing:.06em}
.post-card h2{font-size:1.18rem}
.post-card .excerpt{color:var(--muted);font-size:.92rem;flex:1}
.post-card .tag{align-self:flex-start;font:600 .75rem/1 var(--mono);padding:.3rem .55rem;border-radius:6px;background:var(--accent-soft);color:var(--accent)}

/* ---- Single post ---- */
.post-hero{margin-block:1.2rem 2rem}
.post-hero .thumb{aspect-ratio:16/9;border-radius:18px;overflow:hidden;background:var(--sage-soft);margin-bottom:1.3rem}
.post-hero .thumb img{width:100%;height:100%;object-fit:cover}
.post-hero h1{font-size:clamp(1.9rem,5vw,2.6rem);max-width:24ch}
.post-meta{display:flex;flex-wrap:wrap;gap:.6rem;align-items:center;margin-top:.8rem;font:500 .85rem/1 var(--mono);color:var(--muted)}
.post-meta .tag{font:600 .75rem/1 var(--mono);padding:.35rem .6rem;border-radius:6px;background:var(--accent-soft);color:var(--accent)}

article.post{max-width:70ch;display:grid;gap:1.1rem;padding-block:0 2.4rem}
article.post p{color:var(--ink);font-size:1.05rem}
article.post p.lead{font:500 1.15rem/1.5 var(--body);color:var(--ink)}
article.post blockquote{margin:.6rem 0;padding:1rem 1.3rem;border-left:3px solid var(--accent);background:var(--accent-soft);border-radius:0 12px 12px 0;font:600 1.1rem/1.5 var(--display);color:var(--ink)}
article.post h2{font-size:1.3rem;margin-top:.6rem}
article.post .tips{list-style:none;margin:0;padding:0;display:grid;gap:.9rem;counter-reset:t}
article.post .tips li{counter-increment:t;position:relative;padding-left:2.4rem;color:var(--ink);font-size:1.02rem}
article.post .tips li::before{content:counter(t);position:absolute;left:0;top:-.05rem;font:700 1.1rem/1.6rem var(--display);color:var(--accent-ink);background:var(--accent);width:1.6rem;height:1.6rem;border-radius:50%;text-align:center}
article.post .tips b{font-weight:700}

.post-cta{background:var(--ink);color:var(--ground);border-radius:20px;padding:1.8rem;display:grid;gap:.9rem;margin-block:1rem 2.2rem;justify-items:start}
.post-cta p{color:color-mix(in srgb, var(--ground) 78%, var(--ink))}
.post-cta h2{font-size:1.4rem;color:var(--ground)}

.related{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,220px),1fr));gap:.8rem;margin-top:1rem}
.related a{display:block;background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:.9rem 1rem;text-decoration:none}
.related a:hover{border-color:var(--accent)}
.related b{font:700 1rem/1.3 var(--display);display:block}
.related span{font:400 .8rem/1.4 var(--mono);color:var(--muted)}

footer{padding-block:2rem 3rem;border-top:1px solid var(--line);display:flex;flex-wrap:wrap;justify-content:space-between;gap:1rem;color:var(--muted);font-size:.9rem}
footer a{text-decoration:none}
footer .links{display:flex;gap:1.2rem;flex-wrap:wrap}
.back{display:inline-flex;align-items:center;gap:.4rem;font:500 .92rem/1 var(--body);text-decoration:none;color:var(--muted);margin-top:.4rem}
.back:hover{color:var(--ink)}

.disclaimer{margin-top:2rem;padding:1rem 1.2rem;border-radius:12px;background:var(--sage-soft);color:var(--muted);font-size:.85rem}

/* main navigation (shared with the front page) */
nav ul{display:flex;gap:1.4rem;list-style:none;margin:0;padding:0}
nav a{text-decoration:none;font-weight:500;color:var(--muted)}
nav a:hover,nav .current-menu-item > a{color:var(--ink)}
@media (max-width:820px){nav{display:none}}
.top .btn{padding:.6rem 1rem;font-size:.92rem}

/* WordPress blocks inside posts */
article.post blockquote p{font:inherit;color:inherit;margin:0}
article.post h2,article.post h3{font-family:var(--display)}
article.post ul,article.post ol:not(.tips){margin:0;padding-left:1.3rem;display:grid;gap:.4rem}
article.post figure{margin:0}
article.post figure img{border-radius:14px}
article.post figcaption{font:400 .82rem/1.4 var(--mono);color:var(--muted);margin-top:.4rem}
article.post a{color:var(--accent)}
.post-related{margin-top:.4rem}
.post-related h2{font-size:1.3rem}
.pager{display:flex;justify-content:space-between;gap:1rem;margin-block:-1.5rem 3rem}
.pager a{text-decoration:none;font-weight:600;color:var(--accent)}
