/* The blog wears the application's design language: the same ground, ink, Klein-blue accent and
   12px radius as apps/web/src/index.css, the same self-hosted Outfit, and the same dark mode
   switch (a `.dark` class from localStorage, the media query as the no-script fallback). */
@font-face {
  font-family: 'Outfit Variable';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url('/blog/fonts/outfit-latin-wght-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
:root {
  --bg: #f6f6f4; --surface: #fbfbfa; --surface-2: #efefec; --ink: #121214; --muted: #63636a;
  --line: #e0e0db; --accent: #002fa7; --accent-hover: #0a3fd0; --accent-ink: #f7f8ff; --accent-soft: #e6ebfb;
  --positive: #1c6b47; --critical: #a8261c; --radius: 12px; --radius-sm: 9px;
  color-scheme: light;
}
.dark {
  --bg: #0d0d0f; --surface: #151518; --surface-2: #1d1d21; --ink: #f1f1ef; --muted: #9a9aa2;
  --line: #292930; --accent: #5c7cff; --accent-hover: #7a93ff; --accent-ink: #07070c; --accent-soft: #1a2145;
  --positive: #4fbf8b; --critical: #ff7a6e; color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not(.light) {
    --bg: #0d0d0f; --surface: #151518; --surface-2: #1d1d21; --ink: #f1f1ef; --muted: #9a9aa2;
    --line: #292930; --accent: #5c7cff; --accent-hover: #7a93ff; --accent-ink: #07070c; --accent-soft: #1a2145;
    --positive: #4fbf8b; --critical: #ff7a6e; color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: 'Outfit Variable', ui-sans-serif, system-ui, sans-serif;
  font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent-hover); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
img { max-width: 100%; height: auto; display: block; }

.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-header .inner { max-width: 1120px; margin: 0 auto; padding: 14px 20px; display: flex; align-items: center; gap: 22px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand svg { width: 26px; height: auto; }
.wordmark { text-transform: uppercase; letter-spacing: .06em; line-height: 1; font-size: 15px; }
.wordmark b { font-weight: 600; } .wordmark span { font-weight: 300; }
.site-nav { margin-left: auto; display: flex; gap: 18px; font-size: 14.5px; }
.site-nav a { color: var(--muted); text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current] { color: var(--ink); }
.site-nav .try { color: var(--accent); font-weight: 500; }
.site-nav a { white-space: nowrap; }
/* A phone has room for the wordmark, Blog and the one button that matters. Women and Men stay one
   tap away in the app; at 360px they pushed "Try it on" onto three clipped lines and the page wider
   than the screen. */
@media (max-width: 560px) {
  .site-header .inner { gap: 14px; padding: 12px 16px; }
  .site-nav { gap: 14px; }
  .site-nav .wide-only { display: none; }
}

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.article-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; }
@media (min-width: 1000px) { .article-grid { grid-template-columns: minmax(0, 700px) 300px; column-gap: 64px; } }

.eyebrow { font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.eyebrow a { color: inherit; text-decoration: none; }
.eyebrow a:hover { color: var(--ink); }
h1 { font-size: clamp(32px, 5vw, 46px); line-height: 1.08; font-weight: 500; letter-spacing: -.015em; margin: 36px 0 16px; text-wrap: balance; }
.standfirst { font-size: 19px; line-height: 1.5; color: var(--ink); margin: 0 0 18px; max-width: 62ch; }
.byline { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; color: var(--muted); margin: 0 0 28px; }
.byline a { color: var(--muted); }
.byline time { font-variant-numeric: tabular-nums; }

article { min-width: 0; }
article h2 { font-size: 27px; line-height: 1.2; font-weight: 500; letter-spacing: -.01em; margin: 44px 0 12px; text-wrap: balance; }
article h3 { font-size: 19px; font-weight: 600; margin: 30px 0 8px; }
article p, article ul, article ol { max-width: 66ch; }
article p { margin: 0 0 16px; }
article ul, article ol { padding-left: 22px; margin: 0 0 16px; }
article li { margin: 0 0 6px; }
article li::marker { color: var(--muted); }
article strong { font-weight: 600; }
article table { border-collapse: collapse; width: 100%; font-size: 15px; margin: 8px 0 22px; }
article th, article td { text-align: left; vertical-align: top; padding: 9px 10px; border-bottom: 1px solid var(--line); }
article th { font-weight: 600; color: var(--muted); font-size: 13px; letter-spacing: .02em; }
article td.n, article th.n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table-wrap { overflow-x: auto; margin: 0 0 22px; -webkit-overflow-scrolling: touch; }
/* A table of sentences (markdown.mjs marks it): squeezed to a phone it became one word per line, so
   it keeps a readable width and scrolls sideways inside its box instead. */
.table-wrap.wide table { min-width: 600px; }
article blockquote { margin: 0 0 16px; padding: 4px 0 4px 18px; border-left: 3px solid var(--accent); color: var(--ink); max-width: 62ch; }
article blockquote p { margin: 0 0 6px; }
article hr { border: 0; border-top: 1px solid var(--line); margin: 36px 0; }

.box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin: 22px 0 26px; }
.box.takeaways { border-color: var(--accent-soft); background: var(--accent-soft); }
.dark .box.takeaways { background: var(--accent-soft); }
.box p:last-child, .box ul:last-child { margin-bottom: 0; }
.box ul { padding-left: 20px; }
.box.takeaways > p:first-child { font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }

.render, .render-row { margin: 22px 0 26px; }
.render-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
figure.render { margin: 22px 0 26px; }
.render-row figure.render { margin: 0; }
figure.render img, .render.placeholder { border-radius: var(--radius); background: var(--surface-2); }
figure.render figcaption { font-size: 13.5px; color: var(--muted); margin-top: 8px; line-height: 1.45; }
/* The caption under a render of catalogue pieces: name, price, try it on, and the marked shop link. */
figcaption.shop .shop-label { display: block; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 4px; }
figcaption.shop ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
figcaption.shop li { margin: 0; }
figcaption.shop .shop-name { color: var(--ink); }
figcaption.shop .shop-name b { font-weight: 600; }
figcaption.shop .shop-price { font-variant-numeric: tabular-nums; color: var(--ink); white-space: nowrap; }
figcaption.shop a { white-space: nowrap; font-weight: 500; }
figcaption.shop .shop-try { color: var(--accent); margin-left: 2px; }
figcaption.shop .shop-buy { color: var(--ink); margin-left: 8px; }
figcaption.shop .shop-aff { font-size: 11.5px; color: var(--muted); margin-left: 4px; white-space: nowrap; }
.render.placeholder { aspect-ratio: 3 / 4; display: flex; align-items: flex-end; padding: 14px; border: 1px dashed var(--line); color: var(--muted); font-size: 13.5px; line-height: 1.4; }

.cta { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin: 26px 0 30px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.cta-button { display: inline-block; background: var(--accent); color: var(--accent-ink); text-decoration: none; font-weight: 500; padding: 11px 18px; border-radius: var(--radius-sm); font-size: 15.5px; }
.cta-button:hover { background: var(--accent-hover); color: var(--accent-ink); }
.cta-note { margin: 0; font-size: 13.5px; color: var(--muted); max-width: 52ch; }

.side { font-size: 14px; }
@media (min-width: 1000px) { .side { position: sticky; top: 24px; align-self: start; } }
.toc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 0 0 18px; }
.toc p { margin: 0 0 8px; font-size: 12.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.toc ol { list-style: none; padding: 0; margin: 0; }
.toc li { margin: 0 0 6px; }
.toc a { color: var(--ink); text-decoration: none; }
.toc a:hover { color: var(--accent); }
.side .cta { margin: 0 0 18px; }

.author { display: grid; grid-template-columns: 52px 1fr; gap: 14px; align-items: start; border-top: 1px solid var(--line); padding-top: 24px; margin-top: 40px; }
.author .avatar { width: 52px; height: 52px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 600; font-size: 18px; overflow: hidden; }
.author .avatar.photo img { width: 100%; height: 100%; object-fit: cover; }
.author.profile { border-top: 0; padding-top: 0; margin-top: 12px; grid-template-columns: 96px 1fr; align-items: center; }
.author.profile .avatar { width: 96px; height: 96px; font-size: 30px; }
.author p { margin: 0; font-size: 14.5px; color: var(--muted); }
.author p b { color: var(--ink); font-weight: 600; }
.disclosure { font-size: 13.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 14px; margin-top: 22px; max-width: 66ch; }
.disclosure.top { border-top: 0; border-bottom: 1px solid var(--line); padding: 0 0 12px; margin: -10px 0 24px; }
.disclosure a { color: var(--muted); }

.related { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 24px; }
.related h2 { font-size: 15px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; font-weight: 500; }
.related ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.related a { color: var(--ink); text-decoration: none; font-weight: 500; }
.related a:hover { color: var(--accent); }
.related small { display: block; color: var(--muted); font-weight: 400; }

.site-footer { border-top: 1px solid var(--line); margin-top: 64px; padding: 26px 0 60px; font-size: 13.5px; color: var(--muted); }
.site-footer .inner { max-width: 1120px; margin: 0 auto; padding: 0 20px; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { color: var(--muted); }

.sticky-cta { position: fixed; left: 0; right: 0; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); display: none; align-items: center; gap: 10px; z-index: 20; box-shadow: 0 -6px 20px rgba(0,0,0,.06); }
.sticky-cta.on { display: flex; }
.sticky-cta .cta-button { flex: 1; text-align: center; padding: 11px 14px; }
.sticky-cta .close { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: var(--radius-sm); width: 40px; height: 42px; font-size: 18px; cursor: pointer; }
@media (min-width: 768px) { .sticky-cta { display: none !important; } }

/* index */
.post-list { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 18px; }
@media (min-width: 720px) { .post-list { grid-template-columns: 1fr 1fr; } }
.post-list li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; }
.post-list a { color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 500; line-height: 1.25; }
.post-list a:hover { color: var(--accent); }
.post-list p { margin: 10px 0 0; color: var(--muted); font-size: 15px; }
.post-list time { display: block; margin-top: 10px; font-size: 13px; color: var(--muted); }
