/* Blog index and article pages.
   Black, grey and white only: hairline boxes, large quiet titles, greyscale
   covers that take their colour back on hover. Loaded after blog-article.css
   on article pages, where it replaces that sheet's layout and retunes its prose. */

html.public-site:has(main.lx-page) { --background: #0a0a0a; background-color: #0a0a0a; }
html.public-site:has(main.lx-page) body { background-color: #0a0a0a; }

.lx-page {
    --lx-bg: #0a0a0a;
    --lx-rule: #252525;
    --lx-rule-strong: #3a3a3a;
    --lx-text: #9a9a9a;
    --lx-strong: #fff;
    --lx-gutter: clamp(1.25rem, 3.2vw, 2.875rem);
    --lx-wide: min(88.5rem, calc(100vw - 2 * var(--lx-gutter)));
    --lx-column: 41.5rem;
    --lx-ease: cubic-bezier(.22, 1, .36, 1);
    --background: var(--lx-bg);
    min-height: 100vh;
    padding-top: 4.5rem;
    overflow-x: clip;
    background: var(--lx-bg);
    color: var(--lx-text);
    font-size: 1rem;
    line-height: 1.5;
}
.lx-rail { width: var(--lx-wide); margin-inline: auto; }
.lx-page .sf { --sf-bg: var(--lx-bg); --sf-rail: var(--lx-wide); }
/* The navigation lines up with this page's wider content. */
.lx-page .site-navbar { --nav-rail: var(--lx-wide); }
.lx-page .vn-bar { width: var(--lx-wide); max-width: none; }

.lx-arrow { flex: none; transition: transform 240ms var(--lx-ease); }
.lx-label {
    display: block;
    color: var(--lx-text);
    font-size: .75rem;
    line-height: 1.125rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

/* ── Index: masthead ───────────────────────────────────── */

.lx-masthead {
    position: relative;
    isolation: isolate;
    padding: clamp(3rem, 9vh, 6.5rem) 0 clamp(3.5rem, 9vh, 6.5rem);
    text-align: center;
}
/* The same point grid as the home page hero, faded at the edges. */
.lx-masthead::before {
    content: '';
    position: absolute;
    inset: 0 calc((100vw - 100%) / -2);
    z-index: -1;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Crect x='11' y='11' width='3' height='3' fill='%23202020'/%3E%3C/svg%3E") center / 24px 24px;
    -webkit-mask-image: radial-gradient(ellipse 62% 78% at 50% 46%, #000 20%, transparent 78%);
            mask-image: radial-gradient(ellipse 62% 78% at 50% 46%, #000 20%, transparent 78%);
}
.lx-tagline {
    margin: 0;
    color: var(--lx-text);
    font-size: clamp(1.05rem, 1.7vw, 1.5rem);
    line-height: 1.5;
    letter-spacing: -.015em;
}
.lx-tagline span { color: var(--lx-strong); }
.lx-wordmark {
    margin: clamp(.25rem, 1vw, .75rem) 0 0;
    color: var(--lx-strong);
    font-size: clamp(5.5rem, 22vw, 19rem);
    font-weight: 300;
    line-height: .86;
    letter-spacing: -.065em;
}

/* ── Index: feature card ───────────────────────────────── */

.lx-feature {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    border: 1px solid var(--lx-rule);
    color: inherit;
    text-decoration: none;
}
.lx-feature + .lx-feature { margin-top: clamp(1rem, 1.7vw, 1.5rem); }
.lx-feature-media { position: relative; min-height: clamp(18rem, 36vw, 31rem); overflow: hidden; background: #111; }
.lx-feature--flip .lx-feature-media { order: 2; }
.lx-cover {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(1) contrast(1.04);
    transition: filter 500ms ease, transform 900ms var(--lx-ease);
}
:is(.lx-feature, .lx-card):hover .lx-cover { filter: none; transform: scale(1.02); }

.lx-feature-body { display: flex; flex-direction: column; min-width: 0; }
.lx-feature-text { flex: 1; padding: clamp(1.5rem, 2.6vw, 2.25rem) clamp(1.25rem, 2.4vw, 2rem) clamp(2rem, 4vw, 3rem); }
.lx-feature-title {
    max-width: 22ch;
    margin: 0;
    color: var(--lx-strong);
    font-size: clamp(1.75rem, 3.05vw, 2.75rem);
    font-weight: 400;
    line-height: 1.12;
    letter-spacing: -.03em;
    text-wrap: balance;
}
.lx-feature-excerpt {
    max-width: 46ch;
    margin: clamp(.9rem, 1.4vw, 1.25rem) 0 0;
    font-size: 1rem;
    line-height: 1.5;
}
.lx-cells { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--lx-rule); }
.lx-cell { min-width: 0; padding: 1.3rem clamp(1rem, 1.7vw, 1.5rem) 1.25rem; }
.lx-cell + .lx-cell { border-left: 1px solid var(--lx-rule); }
.lx-cell-value { display: block; margin-top: .15rem; color: var(--lx-strong); font-size: .875rem; line-height: 1.375rem; }
.lx-cell--go {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .7rem;
    color: var(--lx-strong);
    font-size: .875rem;
}
:is(.lx-feature, .lx-card):hover .lx-arrow { transform: translate3d(4px, 0, 0); }

/* ── Index: filters ────────────────────────────────────── */

.lx-tools {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin: clamp(2rem, 4vw, 3.5rem) 0 clamp(1rem, 1.7vw, 1.5rem);
}
.lx-filters { display: flex; flex-wrap: wrap; gap: .25rem; margin: 0; padding: 0; list-style: none; }
.lx-filters a {
    display: block;
    padding: .34rem .875rem;
    border-radius: 999px;
    color: var(--lx-text);
    font-size: .875rem;
    line-height: 1.5rem;
    text-decoration: none;
    white-space: nowrap;
    transition: color 160ms ease, background-color 160ms ease;
}
.lx-filters a:hover { color: var(--lx-strong); }
.lx-filters a[aria-current] { background: var(--lx-rule); color: var(--lx-strong); }
.lx-search {
    flex: none;
    display: flex;
    align-items: center;
    gap: .6rem;
    width: min(16rem, 40vw);
    padding: .45rem 0;
    border-bottom: 1px solid var(--lx-rule-strong);
    color: var(--lx-text);
}
.lx-search svg { flex: none; width: .95rem; height: .95rem; }
.lx-search input {
    flex: 1;
    min-width: 0;
    padding: 0;
    border: 0;
    outline: 0;
    background: none;
    color: var(--lx-strong);
    font-size: .875rem;
    line-height: 1.5rem;
}
.lx-search input::placeholder { color: var(--lx-text); }
.lx-search:focus-within { border-color: var(--lx-strong); }

/* ── Cards (index grid and "continue reading") ─────────── */

.lx-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 1.7vw, 1.5rem);
}
.lx-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    border: 1px solid var(--lx-rule);
    color: inherit;
    text-decoration: none;
}
.lx-card[hidden] { display: none; }
.lx-card-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #111; }
.lx-card-body { flex: 1; display: flex; flex-direction: column; padding: clamp(1.25rem, 1.9vw, 1.6rem) clamp(1rem, 1.7vw, 1.5rem) 0; }
.lx-card-title {
    flex: 1;
    max-width: 24ch;
    margin: 0 0 clamp(1.75rem, 3vw, 2.75rem);
    color: var(--lx-strong);
    font-size: clamp(1.25rem, 1.7vw, 1.5rem);
    font-weight: 400;
    line-height: 1.25;
    letter-spacing: -.02em;
    text-wrap: balance;
}
.lx-card-foot {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .95rem 0;
    border-top: 1px solid var(--lx-rule);
    font-size: .875rem;
    line-height: 1.375rem;
}
.lx-card-foot span:nth-child(2) { margin-right: auto; }
.lx-card-go { display: flex; align-items: center; gap: .7rem; color: var(--lx-strong); white-space: nowrap; }
.lx-empty { grid-column: 1 / -1; margin: 0; padding: 3rem 0; border-top: 1px solid var(--lx-rule); }
.lx-index-end { height: clamp(4rem, 8vw, 7rem); }

:is(.lx-feature, .lx-card, .lx-filters a):focus-visible { outline: 2px solid var(--lx-strong); outline-offset: 3px; }

/* ── Article: head ─────────────────────────────────────── */

.lx-article-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    margin-top: clamp(1.5rem, 4.4vw, 4rem);
    border: 1px solid var(--lx-rule);
}
.lx-article-head--plain { grid-template-columns: minmax(0, 1fr); }
.lx-article-media { position: relative; min-height: clamp(16rem, 34.5vw, 31rem); margin: 0; overflow: hidden; background: #111; }
.lx-article-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; }
.lx-article-info { display: flex; flex-direction: column; min-width: 0; padding: 0 clamp(1.25rem, 2.3vw, 2.05rem); }
.lx-article-title {
    flex: 1;
    max-width: 21ch;
    margin: 0;
    padding: clamp(1.5rem, 2.4vw, 2.1rem) 0 clamp(2.5rem, 6vw, 5rem);
    color: var(--lx-strong);
    font-size: clamp(1.9rem, 3.05vw, 2.75rem);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -.03em;
    text-wrap: balance;
}
.lx-article-head--plain .lx-article-title { max-width: 26ch; font-size: clamp(2.1rem, 4.4vw, 4rem); }
.lx-byline { padding: 1.3rem 0 1.25rem; border-top: 1px solid var(--lx-rule); }
.lx-byline-row { display: flex; align-items: center; gap: .9rem; margin-top: .7rem; }
.lx-byline-mark {
    flex: none;
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: var(--lx-rule);
}
.lx-byline-mark img { width: 1.35rem; height: 1.35rem; object-fit: contain; }
.lx-byline-name { display: block; color: var(--lx-strong); font-size: .875rem; line-height: 1.375rem; }
.lx-byline-role { display: block; font-size: .875rem; line-height: 1.375rem; }
.lx-article-info .lx-cells { margin-inline: calc(clamp(1.25rem, 2.3vw, 2.05rem) * -1); padding-inline: clamp(1.25rem, 2.3vw, 2.05rem); }
.lx-article-info .lx-cell:first-child { padding-left: 0; }

/* ── Article: body ─────────────────────────────────────── */

.lx-article { padding: clamp(3rem, 7vw, 6.25rem) 0 clamp(3rem, 6vw, 5rem); }
.lx-column { width: min(var(--lx-column), calc(100vw - 2 * var(--lx-gutter))); margin-inline: auto; }

.lx-lead {
    margin: 0 0 clamp(1.75rem, 2.6vw, 2.25rem);
    color: var(--lx-strong);
    font-size: clamp(1.2rem, 1.55vw, 1.375rem);
    line-height: 1.45;
    letter-spacing: -.018em;
    text-wrap: pretty;
}

.lx-page .ab-article-body {
    max-width: none;
    color: var(--lx-text);
    font-size: 1rem;
    line-height: 1.5;
}
.lx-page .ab-article-body p { margin: 0 0 1.5rem; color: var(--lx-text); font-size: 1rem; line-height: 1.5; }
.lx-page .ab-article-body :is(h1, h2, h3, h4) { color: var(--lx-strong); font-weight: 400; text-wrap: balance; scroll-margin-top: 6rem; }
.lx-page .ab-article-body :is(h1, h2) {
    margin: clamp(3rem, 5vw, 4.5rem) 0 clamp(1.5rem, 2.4vw, 2.1rem);
    font-size: clamp(1.9rem, 3.05vw, 2.75rem);
    line-height: 1.1;
    letter-spacing: -.03em;
}
.lx-page .ab-article-body h3 { margin: clamp(2.25rem, 3.4vw, 3rem) 0 clamp(1.1rem, 1.9vw, 1.75rem); font-size: 1.375rem; line-height: 1.3; letter-spacing: -.02em; }
.lx-page .ab-article-body h4 { margin: 2rem 0 1rem; font-size: 1.0625rem; line-height: 1.4; font-weight: 500; letter-spacing: -.01em; }
.lx-page .ab-article-body > :first-child { margin-top: 0; }
.lx-page .ab-article-body :is(strong, b) { color: var(--lx-strong); font-weight: 600; }
.lx-page .ab-article-body a {
    color: var(--lx-strong);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: .18em;
    transition: color 160ms ease;
}
.lx-page .ab-article-body a:hover { color: var(--lx-text); }
.lx-page .ab-article-body :is(ul, ol) { margin: 0 0 1.5rem; padding-left: 1.25rem; }
.lx-page .ab-article-body ul { list-style: square; }
.lx-page .ab-article-body ol { list-style: decimal; }
.lx-page .ab-article-body li { margin: 0 0 .5rem; color: var(--lx-text); font-size: 1rem; line-height: 1.5; }
.lx-page .ab-article-body li::marker { color: #5c5c5c; }
.lx-page .ab-article-body blockquote {
    margin: 2rem 0;
    padding: 0 0 0 1.25rem;
    border: 0;
    border-left: 1px solid var(--lx-strong);
    background: none;
    color: var(--lx-strong);
    font-size: 1.125rem;
    line-height: 1.5;
    font-style: normal;
}
.lx-page .ab-article-body blockquote p { margin: 0; color: inherit; font-size: inherit; }
.lx-page .ab-article-body hr { margin: clamp(2.5rem, 4vw, 3.5rem) 0; border: 0; border-top: 1px solid var(--lx-rule); }
.lx-page .ab-article-body code {
    padding: .1em .35em;
    border: 0;
    border-radius: 3px;
    background: #1c1c1c;
    color: #e2e2e2;
    font-size: .875em;
}
.lx-page .ab-article-body pre {
    margin: 2rem 0;
    padding: 1.1rem 1.25rem;
    border: 1px solid var(--lx-rule);
    border-radius: 0;
    background: #0f0f0f;
    font-size: .8125rem;
    line-height: 1.6;
}
.lx-page .ab-article-body pre code { padding: 0; background: none; color: inherit; font-size: inherit; }
.lx-page .ab-article-body img { border: 1px solid var(--lx-rule); border-radius: 0; }
.lx-page .ab-article-body :is(p:has(> img), .ab-article-figure) { margin: clamp(2rem, 3.4vw, 3rem) 0; }
.lx-page .ab-article-body .ab-article-figure > figcaption { margin-top: .75rem; color: var(--lx-text); font-size: .8125rem; line-height: 1.4; text-align: left; }

/* Tables leave the reading column and take the full page width, where their
   columns have room. Header in white, body rows banded. */
.lx-page .ab-table-scroll {
    position: relative;
    left: 50%;
    width: var(--lx-wide);
    max-width: none;
    margin: clamp(2.5rem, 5vw, 4.5rem) 0;
    padding: 0;
    overflow-x: auto;
    border: 0;
    border-radius: 0;
    background: none;
    transform: translateX(-50%);
}
.lx-page .ab-article-body table {
    width: 100%;
    min-width: 0;
    margin: 0;
    border: 0;
    border-collapse: collapse;
    border-radius: 0;
    font-size: .8125rem;
    line-height: 1.375rem;
}
.lx-page .ab-article-body :is(th, td) {
    padding: .7rem .8rem;
    border: 1px solid var(--lx-rule-strong);
    text-align: left;
    vertical-align: top;
}
.lx-page .ab-article-body th {
    border-color: #d4d4d4;
    background: #fff;
    color: #0a0a0a;
    font-size: .8125rem;
    font-weight: 400;
    letter-spacing: 0;
    text-transform: none;
    white-space: nowrap;
}
.lx-page .ab-article-body td { background: var(--lx-bg); color: var(--lx-text); font-size: .8125rem; }
.lx-page .ab-article-body tbody tr:nth-child(even) td { background: #1b1b1b; }
.lx-page .ab-article-body tbody tr:nth-child(odd) td { background: var(--lx-bg); }
.lx-page .ab-article-body tbody tr:hover td { background: #222; }
.lx-page .ab-article-body tbody td:first-child { color: #c4c4c4; font-weight: 400; }
.lx-page .ab-article-body :is(th, td).is-num { text-align: right; font-variant-numeric: tabular-nums; }
.lx-page .ab-article-body tbody tr:last-child td { border-bottom: 1px solid var(--lx-rule-strong); }
.lx-page .ab-article-body tr.is-total td { background: var(--lx-bg); color: var(--lx-strong); font-weight: 600; }
.lx-page .ab-article-body td code { background: none; padding: 0; color: #c4c4c4; }

/* ── Article: contents, as a stack of short lines at the page edge ── */

.lx-toc {
    position: fixed;
    top: 50%;
    left: 0;
    z-index: 20;
    max-height: 70vh;
    margin: 0;
    padding: .75rem 1.25rem .75rem 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateY(-50%);
}
.lx-toc ol { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.lx-toc a {
    display: flex;
    align-items: center;
    gap: .85rem;
    height: .8125rem;
    color: var(--lx-text);
    font-size: .8125rem;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: height 260ms var(--lx-ease);
}
.lx-toc a::before {
    content: '';
    flex: none;
    width: 1.4rem;
    height: 1px;
    background: #5c5c5c;
    transition: width 260ms var(--lx-ease), background-color 200ms ease;
}
.lx-toc a.is-sub::before { width: .95rem; }
.lx-toc a.is-active::before { width: 2rem; background: var(--lx-strong); }
/* Closed, a label takes no room: otherwise the strip would be an invisible
   17rem-wide link lying over the article. */
.lx-toc a span {
    max-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    opacity: 0;
    transform: translate3d(-4px, 0, 0);
    transition: opacity 200ms ease, transform 260ms var(--lx-ease), color 160ms ease;
    pointer-events: none;
}
.lx-toc a.is-sub span { color: #6f6f6f; }
.lx-toc a.is-active span,
.lx-toc a:hover span { color: var(--lx-strong); }
/* Hovering or tabbing into the stack opens it into a readable list. */
.lx-toc:is(:hover, :focus-within) { background: linear-gradient(90deg, var(--lx-bg) 78%, transparent); }
.lx-toc:is(:hover, :focus-within) a { height: 1.75rem; }
.lx-toc:is(:hover, :focus-within) a span { max-width: 17rem; opacity: 1; transform: none; pointer-events: auto; }
.lx-toc a:focus-visible { outline: 2px solid var(--lx-strong); outline-offset: 2px; }
@media (max-width: 1179px) { .lx-toc { display: none; } }

/* ── Article: end matter ───────────────────────────────── */

.lx-endnote {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-top: clamp(3rem, 5vw, 4.5rem);
    padding-top: 1.5rem;
    border-top: 1px solid var(--lx-rule);
    font-size: .875rem;
    line-height: 1.5rem;
}
.lx-subscribe { display: flex; align-items: center; gap: .5rem; margin: 0; }
.lx-subscribe input {
    width: 13.5rem;
    max-width: 46vw;
    padding: .4rem 0;
    border: 0;
    border-bottom: 1px solid var(--lx-rule-strong);
    outline: 0;
    background: none;
    color: var(--lx-strong);
    font-size: .875rem;
    line-height: 1.5rem;
}
.lx-subscribe input::placeholder { color: var(--lx-text); }
.lx-subscribe input:focus { border-color: var(--lx-strong); }
.lx-pill {
    padding: .34rem .875rem;
    border: 0;
    border-radius: 999px;
    background: var(--lx-rule);
    color: var(--lx-strong);
    font-size: .875rem;
    line-height: 1.5rem;
    cursor: pointer;
    transition: background-color 160ms ease;
}
.lx-pill:hover { background: var(--lx-rule-strong); }
.lx-endnote-links { display: flex; align-items: center; gap: 1.25rem; }
.lx-link { padding: 0; border: 0; background: none; color: var(--lx-strong); font-size: .875rem; text-decoration: underline; text-underline-offset: .18em; cursor: pointer; }
.lx-page .ab-copied { color: var(--lx-text); font-size: .875rem; font-weight: 400; }
.lx-subscribe-note { margin: 0; color: var(--lx-strong); }

.lx-page .ab-mentions { margin: clamp(2rem, 3vw, 2.5rem) 0 0; padding: 1.25rem 0 0; border: 0; border-top: 1px solid var(--lx-rule); border-radius: 0; background: none; }
.lx-page .ab-mentions-label { color: var(--lx-text); font-size: .75rem; font-weight: 400; letter-spacing: .06em; }
.lx-page .ab-mention { border-color: var(--lx-rule-strong); background: none; color: var(--lx-strong); }
.lx-page .ab-mention span { color: var(--lx-text); }

.lx-more { padding-bottom: clamp(4rem, 8vw, 7rem); }
.lx-more-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: clamp(1rem, 1.7vw, 1.5rem);
    padding-top: clamp(1.25rem, 2vw, 1.75rem);
    border-top: 1px solid var(--lx-rule);
}
.lx-more-title { margin: 0; color: var(--lx-strong); font-size: 1.5rem; font-weight: 400; line-height: 1.3; letter-spacing: -.02em; }
.lx-more-all { display: flex; align-items: center; gap: .7rem; color: var(--lx-strong); font-size: .875rem; text-decoration: none; }
.lx-more-all:hover .lx-arrow { transform: translate3d(4px, 0, 0); }

/* ── Smaller screens ───────────────────────────────────── */

@media (max-width: 1079px) {
    .lx-page { padding-top: 3.75rem; }
}
@media (max-width: 899px) {
    .lx-feature,
    .lx-article-head { grid-template-columns: minmax(0, 1fr); }
    .lx-feature--flip .lx-feature-media { order: 0; }
    .lx-feature-media,
    .lx-article-media { min-height: 0; aspect-ratio: 16 / 10; }
    .lx-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lx-tools { flex-direction: column; align-items: stretch; }
    .lx-filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .lx-filters::-webkit-scrollbar { display: none; }
    .lx-search { width: auto; }
}
@media (max-width: 599px) {
    .lx-grid { grid-template-columns: minmax(0, 1fr); }
    .lx-cells { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lx-feature .lx-cell--go { grid-column: 1 / -1; justify-content: flex-start; border-left: 0; border-top: 1px solid var(--lx-rule); }
    .lx-article-info .lx-cell:nth-child(3) { grid-column: 1 / -1; padding-left: 0; border-left: 0; border-top: 1px solid var(--lx-rule); }
    .lx-endnote { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
    .lx-cover, .lx-arrow, .lx-toc a, .lx-toc a::before, .lx-toc a span { transition: none; }
}

/* A card the search has filtered out. */
.lx-feature[hidden], .lx-card[hidden] { display: none; }

/* The film-grain overlay that the shared page footer can add is not part of
   this page's design. */
.site-grain { display: none; }
