/* Injection Log / Bullet Diary theme. See agent/design-guidelines.md */
:root {
  color-scheme: light;
  --bg: #faf3e8; --surface: #ffffff; --surface-2: #f0e7d6; --ink: #26221e; --muted: #6b6355; --rule: #e2d5bd;
  --link: #a3384f; --focus: #d9637a;
  --panel: #161c26; --panel-2: #1e2632; --panel-ink: #faf3e8; --panel-muted: #a9b0bb;
  --navy: #26344a; --coral: #d9637a; --olive: #6d6b3a;
  --display: "Spectral", Georgia, "Times New Roman", serif;
  --serif: "Spectral", Georgia, "Times New Roman", serif;
  --hand: "Special Elite", "Courier New", monospace;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --wrapw: 72rem;
  --r: 10px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #161c26; --surface: #1e2632; --surface-2: #1a212b; --ink: #f0ece2; --muted: #a9aeb8; --rule: #303a48;
  --link: #ec91a1; --focus: #e07d90;
  --panel: #10141c; --panel-2: #171e28;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #161c26; --surface: #1e2632; --surface-2: #1a212b; --ink: #f0ece2; --muted: #a9aeb8; --rule: #303a48;
    --link: #ec91a1; --focus: #e07d90;
    --panel: #10141c; --panel-2: #171e28;
  }
}

/* topic tones: --c fill, --c-ink text on fill, --c-text text on page */
.t-olive  { --c: #6d6b3a; --c-ink: #f4f2e2; --c-text: #57552e; }
.t-coral  { --c: #d9637a; --c-ink: #fff0f3; --c-text: #b64d63; }
.t-navy   { --c: #26344a; --c-ink: #eef1f5; --c-text: #26344a; }
:root[data-theme="dark"] .t-olive  { --c-text: #b7b473; }
:root[data-theme="dark"] .t-coral  { --c-text: #ec91a1; }
:root[data-theme="dark"] .t-navy   { --c-text: #9fb0c8; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .t-olive  { --c-text: #b7b473; }
  :root:not([data-theme="light"]) .t-coral  { --c-text: #ec91a1; }
  :root:not([data-theme="light"]) .t-navy   { --c-text: #9fb0c8; }
}

@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  html { scroll-behavior: smooth; }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--ink); font: 400 1.06rem/1.68 var(--serif); overflow-x: hidden; transition: background-color .25s, color .25s; padding-bottom: env(safe-area-inset-bottom); }
main { flex: 1; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: .2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--coral); color: #fff0f3; }
h1, h2, h3 { font-family: var(--display); line-height: 1.14; margin: 0; font-weight: 600; letter-spacing: -.006em; text-wrap: balance; }
p { text-wrap: pretty; }
.wrap { width: min(var(--wrapw), 100% - 2rem); margin-inline: auto; padding-inline: env(safe-area-inset-left) env(safe-area-inset-right); }
.short { display: none; }
.sec-title { font-size: clamp(1.55rem, 3vw, 2.2rem); font-weight: 600; }

/* ---------- shop strip ---------- */
.shopbar { background: var(--panel); color: var(--panel-ink); font: 500 .84rem/1.4 var(--serif); border-bottom: 1px solid rgba(255,255,255,.08); }
.shopbar-in { width: min(var(--wrapw), 100% - 2rem); margin-inline: auto; padding: .5rem 0; display: flex; gap: .9rem; align-items: baseline; justify-content: center; white-space: nowrap; overflow: hidden; }
.shopbar-in > span { overflow: hidden; text-overflow: ellipsis; color: var(--panel-muted); }
.shopbar a { color: #ec91a1; font-weight: 700; text-decoration: none; }
.shopbar a:hover { text-decoration: underline; }
.shopbar a span { display: inline-block; transition: transform .15s; }
.shopbar a:hover span { transform: translateX(3px); }

/* ---------- masthead ---------- */
.bar { background: var(--bg); border-bottom: 1px solid var(--rule); }
.bar-in { width: min(var(--wrapw), 100% - 2rem); margin-inline: auto; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .5rem 2rem; padding: .9rem 0; }
.brand { color: var(--ink); text-decoration: none; }
.logo { display: inline-flex; align-items: center; gap: .55rem; }
.logo-mark { width: 1.7rem; height: 1.7rem; flex: none; transition: transform .3s ease; }
.brand:hover .logo-mark { transform: rotate(-4deg); }
.lm-page { stroke: var(--navy); }
.lm-dot { fill: var(--navy); opacity: .4; }
.lm-marked { fill: var(--coral); opacity: 1; }
.brand-name { font: 600 1.35rem/1 var(--display); letter-spacing: -.006em; }
.brand-name em { font: italic 500 1em/1 var(--serif); color: var(--coral); font-style: italic; padding-right: .08em; }
.bar nav { display: flex; justify-content: flex-end; gap: .25rem; font: 600 .88rem/1.2 var(--serif); white-space: nowrap; }
.bar nav a { color: var(--muted); text-decoration: none; padding: .55rem .75rem; border-radius: 7px; transition: color .15s, background-color .15s; }
.bar nav a:hover { color: var(--ink); background: var(--surface-2); }
.bar nav a[aria-current] { color: var(--ink); background: var(--surface-2); box-shadow: inset 0 -2px 0 var(--coral); }
.theme-toggle { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 9px; border: 1px solid var(--rule); background: var(--surface); color: var(--ink); cursor: pointer; transition: transform .2s, border-color .2s; }
.theme-toggle:hover { border-color: var(--coral); }
.theme-toggle svg { width: 1.15rem; height: 1.15rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.theme-toggle .i-moon { fill: currentColor; stroke: none; }
.theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: none; }

/* header stays the same plain notebook-page style on every page, home included --
   the hero below is what carries this site's identity, not a dark masthead. */

@media (max-width: 52rem) {
  .long { display: none; } .short { display: inline; }
  .bar-in { grid-template-columns: 1fr auto; padding: .7rem 0 .4rem; }
  .bar nav { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; margin-inline: -.6rem; gap: 0; overflow-x: auto; scrollbar-width: none; font-size: .84rem; }
  .bar nav a { padding: .5rem .6rem; }
  .bar nav::-webkit-scrollbar { display: none; }
  .brand-name { font-size: 1.2rem; }
}

/* ---------- shared bits ---------- */
.kicker { display: inline-flex; align-items: center; gap: .45rem; margin: 0 0 .6rem; font: 400 .68rem/1 var(--hand); text-transform: uppercase; letter-spacing: .05em; color: var(--c-text, var(--muted)); }
.kicker b, .filters b, .crumb-cat b { display: inline-grid; place-items: center; min-width: 2.1em; height: 1.7em; padding: 0 .3em; border-radius: 4px; background: var(--c, var(--ink)); color: var(--c-ink, var(--bg)); font: 700 .78em/1 var(--mono); letter-spacing: 0; text-transform: none; }
.meta { margin: .8rem 0 0; font: 400 .76rem/1.3 var(--hand); color: var(--muted); letter-spacing: .01em; }
.desc { margin: .5rem 0 0; color: var(--muted); font-size: .97rem; line-height: 1.5; }
.btn { font: 700 .92rem/1 var(--serif); cursor: pointer; border: 1.5px solid var(--ink); background: none; color: var(--ink); padding: .85rem 1.3rem; border-radius: 8px; transition: background .15s, color .15s, transform .15s; }
.btn:hover { background: var(--ink); color: var(--bg); transform: translateY(-2px); }
.empty { color: var(--muted); font-family: var(--serif); }

.btn-shop, .btn-ghost, .btn-dark { display: inline-flex; align-items: center; gap: .6rem; font: 700 1rem/1 var(--serif); text-decoration: none; padding: 1.05rem 1.5rem; border-radius: 8px; transition: transform .2s, box-shadow .2s, background-color .2s, border-color .2s; }
.btn-shop span, .btn-dark span, .read-link span { display: inline-block; transition: transform .2s; }
.btn-shop:hover span, .btn-dark:hover span, .read-link:hover span { transform: translateX(4px); }
.btn-shop { background: var(--coral); color: #33020c; box-shadow: 0 12px 28px -14px rgba(217,99,122,.75); }
.btn-shop:hover { transform: translateY(-3px); background: #c14e65; }
.btn-ghost { color: var(--ink); border: 1.5px solid var(--rule); }
.btn-ghost:hover { border-color: var(--coral); color: var(--link); }
.btn-dark { background: #10141c; color: #faf3e8; box-shadow: 0 14px 30px -16px rgba(0,0,0,.8); }
.btn-dark:hover { transform: translateY(-3px); background: #0b0e14; }

/* ---------- home: hero (dot-grid board + stacked notecard) ---------- */
.hero {
  position: relative; overflow: hidden; background: var(--bg);
  background-image: radial-gradient(var(--rule) 1.3px, transparent 1.3px);
  background-size: 24px 24px;
}
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 4px; background: linear-gradient(90deg, var(--coral) 0 34%, var(--olive) 34% 67%, var(--navy) 67%); }
.hero-in { position: relative; display: grid; gap: 2.5rem; align-items: center; padding: clamp(3rem, 8vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4rem); }
.notecard {
  position: relative; isolation: isolate; background: var(--surface); border: 1px solid var(--rule); border-radius: 3px;
  padding: clamp(1.75rem, 4vw, 2.75rem); box-shadow: 0 22px 38px -26px rgba(20,16,10,.4);
}
.notecard::before, .notecard::after { content: ""; position: absolute; inset: 0; background: var(--surface); border: 1px solid var(--rule); border-radius: 3px; z-index: -1; }
.notecard::before { transform: rotate(-2.4deg) translate(-.35rem, .4rem); z-index: -2; }
.notecard::after { transform: rotate(1.7deg) translate(.4rem, .55rem); }
.dateline { display: inline-flex; align-items: center; gap: .55rem; margin: 0 0 1.2rem; font: 400 .78rem/1 var(--hand); color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.dateline::before { content: ""; width: 1.6rem; height: 2px; background: var(--coral); }
.hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 600; line-height: 1.12; letter-spacing: -.008em; max-width: 18ch; color: var(--ink); }
.hero-sub { margin: 1.3rem 0 0; font-size: clamp(1rem, 1.6vw, 1.12rem); line-height: 1.55; color: var(--muted); max-width: 34rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }
.hero-art { width: 100%; max-width: 18rem; justify-self: center; height: auto; overflow: visible; color: var(--muted); }
@media (min-width: 60rem) {
  .hero-in { grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 3rem; }
  .hero-art { max-width: 22rem; justify-self: end; }
}
@media (max-width: 30rem) { .btn-shop, .btn-ghost { width: 100%; justify-content: center; } }

.ha-trend { stroke: var(--coral); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.ha-shot { fill: var(--bg); stroke: var(--coral); stroke-width: 2.5; }
.ha-label { font: 400 11px var(--hand); fill: var(--muted); text-transform: uppercase; letter-spacing: .04em; }

/* ---------- home: topic markers (dots on a dotted line, not tiles) ---------- */
.markers { padding: clamp(2.5rem, 6vw, 4rem) 0 1rem; }
.marker-row { position: relative; display: flex; justify-content: space-between; gap: 1rem; margin-top: 2.2rem; padding: 0 clamp(.5rem, 4vw, 2rem); }
.marker-row::before { content: ""; position: absolute; left: 8%; right: 8%; top: 1.35rem; border-top: 2px dotted var(--rule); z-index: 0; }
.marker { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: .55rem; text-decoration: none; color: var(--ink); flex: 1; text-align: center; }
.marker-dot { width: 2.7rem; height: 2.7rem; border-radius: 50%; background: var(--c); color: var(--c-ink); display: grid; place-items: center; font: 700 .92rem/1 var(--mono); box-shadow: 0 10px 18px -10px var(--c); transition: transform .2s ease; border: 3px solid var(--bg); }
.marker:hover .marker-dot { transform: translateY(-3px) scale(1.06); }
.marker-label { font: 600 .95rem/1.2 var(--display); }
.marker-count { font: 400 .74rem/1 var(--hand); color: var(--muted); letter-spacing: .02em; }

/* ---------- home: shop band (sticky note) ---------- */
.shopband { padding: clamp(2.5rem, 6vw, 4rem) 0; }
.sticky {
  position: relative; display: block; max-width: 24rem; margin: 0 auto; padding: 1.9rem 2rem 2.1rem;
  background: #fdedac; color: #4a3b06; border-radius: 2px; text-align: center; text-decoration: none;
  box-shadow: 0 20px 34px -22px rgba(20,16,10,.45); transform: rotate(-1.5deg); transition: transform .2s ease;
}
.sticky:hover { transform: rotate(-1.5deg) translateY(-3px); }
.sticky::before { content: ""; position: absolute; top: -.7rem; left: 50%; translate: -50% 0; width: 3.4rem; height: 1.15rem; background: rgba(255,255,255,.5); border: 1px solid rgba(0,0,0,.06); }
.sticky h2 { font-size: clamp(1.15rem, 2.6vw, 1.4rem); font-weight: 600; line-height: 1.25; margin-bottom: 1.1rem; color: #4a3b06; }
.sticky .btn-dark { background: #26221e; color: #fdedac; box-shadow: none; padding: .7rem 1.15rem; font-size: .88rem; }
.sticky-end { max-width: 16rem; padding: 1.1rem 1.4rem; font: 700 1rem/1 var(--serif); }
.sticky-end span { display: inline-block; transition: transform .2s; }
.sticky-end:hover span { transform: translateX(4px); }

/* ---------- lists: vertical timeline log ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.item { position: relative; }
.item[hidden] { display: none; }
.item h2 a::after, .item h3 a::after { content: ""; position: absolute; inset: -.3rem; border-radius: 6px; }
.item h2, .item h3 { font-size: 1.14rem; font-weight: 600; line-height: 1.28; }

.timeline { position: relative; margin: 1.8rem 0 0; padding-left: 0; }
.timeline::before { content: ""; position: absolute; left: .95rem; top: .4rem; bottom: .5rem; width: 2px; background: var(--rule); }
.timeline .item { padding: 0 0 2rem 3.1rem; }
.timeline .item::after { content: ""; position: absolute; left: .45rem; top: .3rem; width: 1rem; height: 1rem; border-radius: 50%; background: var(--c); border: 3px solid var(--bg); }
.timeline .item:last-child { padding-bottom: 0; }
.item-date { display: block; font: 400 .76rem/1 var(--hand); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: .4rem; }
.item h2 a, .item h3 a { color: var(--ink); text-decoration: underline; text-decoration-color: transparent; text-decoration-thickness: 3px; text-underline-offset: .12em; transition: text-decoration-color .2s; }
.item:hover h2 a, .item:hover h3 a { text-decoration-color: var(--c, var(--coral)); }
.item .desc { max-width: 42rem; }
.item .meta { margin-top: .5rem; }
@media (min-width: 46rem) {
  .related .timeline .item { padding-left: 2.6rem; }
}

/* ---------- library, search, filters ---------- */
.library { padding: 3rem 0 1.5rem; }
.lib-head { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between; }
.search { flex: 1 1 18rem; max-width: 28rem; }
.search input { width: 100%; font: 500 1rem var(--serif); color: var(--ink); background: var(--surface) no-repeat .95rem 50% / 1.1rem url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23889890' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='m20 20-4.5-4.5'/%3E%3C/svg%3E"); border: 1.5px solid var(--rule); border-radius: 8px; padding: .85rem 1rem .85rem 2.7rem; transition: border-color .15s, box-shadow .15s; }
.search input::placeholder { color: var(--muted); }
.search input:focus { outline: none; border-color: var(--coral); box-shadow: 0 0 0 4px rgba(217,99,122,.16); }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.25rem 0 0; padding: 0; list-style: none; }
.filters button { display: inline-flex; align-items: center; gap: .45rem; font: 600 .88rem/1 var(--serif); background: var(--surface); border: 1.5px solid var(--rule); padding: .5rem .8rem .5rem .55rem; border-radius: 7px; color: var(--ink); cursor: pointer; transition: border-color .15s, background-color .15s, color .15s, transform .15s; }
.filters [data-chip="all"] { padding-left: .8rem; }
.filters button > span { font: 500 .78em/1 var(--mono); color: var(--muted); }
.filters button:hover { border-color: var(--c, var(--ink)); transform: translateY(-1px); }
.filters button[aria-pressed="true"] { background: var(--c, var(--ink)); border-color: var(--c, var(--ink)); color: var(--c-ink, var(--bg)); }
.filters button[aria-pressed="true"] > span { color: inherit; opacity: .75; }
.filters button[aria-pressed="true"] b { background: rgba(0,0,0,.14); color: inherit; }
.more { margin: 2rem 0; }

/* ---------- category + archive headers ---------- */
.page-head { position: relative; isolation: isolate; display: flex; align-items: center; gap: 1.25rem; padding: clamp(2rem, 5vw, 3.25rem) 0 1.75rem; margin-bottom: .5rem; }
.page-head::before { content: ""; position: absolute; inset: 0 calc(50% - 50vw); z-index: -1; background: linear-gradient(180deg, color-mix(in srgb, var(--c, var(--coral)) 13%, var(--bg)), var(--bg)); border-bottom: 1px solid var(--rule); }
.page-head h1 { font-size: clamp(1.9rem, 5vw, 3.2rem); font-weight: 600; letter-spacing: -.01em; line-height: 1.1; }
.page-head p { color: var(--muted); margin: .8rem 0 0; font-size: 1.04rem; max-width: 38rem; }
.page-head .marker-dot { flex: none; width: clamp(3.4rem, 8vw, 4.2rem); height: clamp(3.4rem, 8vw, 4.2rem); font-size: 1.1rem; }
.library .page-head { padding-top: clamp(2rem, 5vw, 3.25rem); margin-bottom: 1.5rem; }
.library:has(> .page-head:first-child) { padding-top: 0; }

/* ---------- article (kept calm) ---------- */
.art { display: grid; grid-template-columns: minmax(0, 1fr); padding-bottom: 1rem; }
.art-head { position: relative; isolation: isolate; padding: clamp(2rem, 5vw, 3.5rem) 0 2rem; }
.art-head::before { content: ""; position: absolute; inset: 0 calc(50% - 50vw); z-index: -1; background: linear-gradient(180deg, color-mix(in srgb, var(--c) 14%, var(--bg)) 0%, var(--bg) 100%); border-bottom: 1px solid var(--rule); }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font: 400 .78rem/1.4 var(--hand); color: var(--muted); margin: 0 0 1.2rem; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.crumb-cat { display: inline-flex; align-items: center; gap: .4rem; color: var(--c-text) !important; font-weight: 700; }
.art-head h1 { font-size: clamp(1.7rem, 4.2vw, 2.8rem); font-weight: 600; line-height: 1.14; letter-spacing: -.006em; max-width: 22ch; }
.art-lede { font-size: clamp(1.05rem, 1.8vw, 1.2rem); line-height: 1.5; font-style: italic; color: var(--muted); margin: 1.1rem 0 0; max-width: 44rem; }
.art-meta { font: 400 .76rem/1.4 var(--hand); color: var(--muted); margin: 1.2rem 0 0; }
.toc { display: none; }
@media (min-width: 68rem) {
  .art { grid-template-columns: 15rem minmax(0, 44rem); column-gap: 4rem; justify-content: center; }
  .art-head { grid-column: 1 / -1; }
  .toc { display: block; grid-column: 1; grid-row: 2 / span 2; align-self: start; position: sticky; top: 1.5rem; padding-top: 2.4rem; font: 500 .84rem/1.35 var(--serif); }
  .toc p { margin: 0 0 .8rem; font: 400 .68rem/1 var(--hand); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
  .toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--rule); counter-reset: s; }
  .toc li { counter-increment: s; }
  .toc a { display: flex; gap: .6rem; padding: .4rem 0 .4rem .9rem; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; transition: color .15s, border-color .15s; }
  .toc a::before { content: counter(s, decimal-leading-zero); font: 400 .74rem/1.6 var(--hand); opacity: .7; }
  .toc a:hover { color: var(--ink); }
  .toc a[aria-current] { color: var(--c-text); border-left-color: var(--c); }
  .prose, .post-tools { grid-column: 2; }
}

.prose { font-size: 1.06rem; line-height: 1.75; overflow-wrap: anywhere; padding-top: 1rem; max-width: 44rem; }
@media (min-width: 48rem) { .prose { font-size: 1.12rem; } }
.prose p, .prose ul, .prose ol { margin: 1.1em 0; }
.prose h2 { font-size: clamp(1.34rem, 2.4vw, 1.72rem); margin: 2.2em 0 .3em; scroll-margin-top: 1rem; font-weight: 600; }
.prose h2::before { content: ""; display: block; width: 2.2rem; height: 4px; border-radius: 2px; background: var(--c); margin-bottom: .7rem; }
.prose h3 { font-size: 1.12rem; margin: 1.9em 0 .2em; font-weight: 600; }
.prose h2 + p, .prose h3 + p { margin-top: .5em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .35em 0; padding-left: .2em; }
.prose li::marker { color: var(--c-text); font-weight: 700; }
.prose strong { font-weight: 700; }
.prose a { color: var(--link); }
.prose blockquote { margin: 1.8em 0; padding: 1rem 1.25rem; border-radius: 10px; background: color-mix(in srgb, var(--c) 10%, var(--surface)); border-left: 4px solid var(--c); font-style: italic; }
.prose blockquote p { margin: .3em 0; }
.prose hr { border: 0; border-top: 1px solid var(--rule); margin: 2.5em 0; }
.prose code { font: .85em var(--mono); background: var(--surface-2); padding: .12em .35em; border-radius: 5px; }
.table-wrap { overflow-x: auto; margin: 1.8em 0; border: 1px solid var(--rule); border-radius: 12px; background: var(--surface); }
.prose table { width: 100%; border-collapse: collapse; font: 400 .89rem/1.45 var(--serif); font-variant-numeric: tabular-nums; }
.prose th { text-align: left; font: 600 .68rem/1.2 var(--mono); text-transform: uppercase; letter-spacing: .08em; padding: .8rem .9rem; background: var(--ink); color: var(--bg); white-space: nowrap; }
.prose thead tr { box-shadow: inset 0 -3px 0 var(--c); }
.prose td { padding: .7rem .9rem; border-top: 1px solid var(--rule); vertical-align: top; }
.prose tbody tr:nth-child(even) td { background: var(--surface-2); }

.post-tools { display: flex; flex-wrap: wrap; gap: .5rem; margin: 2.5rem 0 0; padding-top: 1.25rem; border-top: 1px solid var(--rule); }
.post-tools a { font: 600 .84rem/1 var(--serif); color: var(--ink); text-decoration: none; padding: .6rem .85rem; border: 1.5px solid var(--rule); border-radius: 8px; transition: border-color .15s; }
.post-tools a:hover { border-color: var(--c); }

.related { padding-top: 3rem; }
.related h2 { font-size: clamp(1.3rem, 2.6vw, 1.75rem); font-weight: 600; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-block: 2rem 3.5rem; }
.end-shop { text-align: center; margin-block: 0 4rem; }
.pager a { display: block; padding: 1.1rem 1.25rem; border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); color: var(--ink); text-decoration: none; font: 700 1rem/1.3 var(--serif); transition: border-color .2s, transform .2s; }
.pager a:hover { border-color: var(--coral); transform: translateY(-2px); }
.pager span { display: block; font: 400 .68rem/1 var(--hand); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: .5rem; }
.pager .next { text-align: right; }
@media (max-width: 36rem) { .pager { grid-template-columns: 1fr; } .pager .next { text-align: left; } }

/* ---------- footer ---------- */
.foot { position: relative; margin-top: 3rem; padding: 3rem 0 2rem; color: var(--panel-muted); font: 400 .92rem/1.5 var(--serif); background: var(--panel); }
.foot::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: linear-gradient(90deg, var(--coral) 0 34%, var(--olive) 34% 67%, var(--navy) 67%); }
.is-home .foot { margin-top: 1rem; }
.foot-in { width: min(var(--wrapw), 100% - 2rem); margin-inline: auto; display: flex; flex-wrap: wrap; gap: 1.5rem 3rem; justify-content: space-between; align-items: flex-end; }
.foot p { margin: 0; max-width: 26rem; }
.foot-brand { margin-bottom: .7rem !important; color: var(--panel-ink); }
.foot-brand .brand-name { font-size: 1.7rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: .5rem 1.3rem; }
.foot nav a { display: inline-flex; align-items: center; gap: .45rem; color: var(--panel-ink); text-decoration: none; font-weight: 600; }
.foot nav a i { width: .6rem; height: .6rem; border-radius: 2px; background: var(--c); }
.foot nav a span { font: 400 .78rem var(--mono); color: var(--panel-muted); }
.foot nav a:hover { text-decoration: underline; text-decoration-color: var(--c); }
.foot-copy { width: min(var(--wrapw), 100% - 2rem); margin: 2rem auto 0 !important; padding-top: 1.2rem; border-top: 1px solid rgba(255,255,255,.1); font: 400 .76rem/1 var(--mono); max-width: none !important; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
