/* ============================================================
   NORTHBEAMS LABS
   A publication stylesheet, not a marketing one.

   Deliberate differences from northbeams-site/styles.css:
     serif body type instead of Archivo, one column at reading
     measure instead of card grids, hairline rules instead of
     rounded panels, no gold field, no gradients, no motion.
   Deliberate similarities: the same paper cream and the same
   ink navy, so it still reads as the same company.

   Everything is system fonts and local files. The site makes
   no third-party request of any kind, which is also why the
   content security policy can stay as tight as it is.
   ============================================================ */

:root {
  color-scheme: light dark;

  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", "Hoefler Text", Georgia, "Times New Roman", serif;
  /* Menlo before ui-monospace on purpose: SF Mono draws a double hyphen as one
     long stroke, so a flag like --json reads as punctuation this style bans */
  --mono: Menlo, Consolas, "DejaVu Sans Mono", "Liberation Mono", ui-monospace, monospace;

  --measure: 34rem;          /* about 70 characters at the body size */
  --step: 1.7rem;

  /* light (paper) */
  --paper: #F6F3EC;
  --ink: #14262E;
  --muted: #4A5C63;
  --rule: rgba(20, 38, 46, .18);
  --rule-soft: rgba(20, 38, 46, .10);
  --link: #10495A;
  --tint: #EFEBE0;
  --bar: #14262E;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #101A1F;
    --ink: #E7E3D9;
    --muted: #A6B2B4;
    --rule: rgba(231, 227, 217, .22);
    --rule-soft: rgba(231, 227, 217, .12);
    --link: #8FD0D6;
    --tint: #17232A;
    --bar: #8FD0D6;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.0625rem, 1rem + .3vw, 1.1875rem);
  line-height: 1.62;
  text-rendering: optimizeLegibility;
}

.nl-wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ---------- links and focus ---------- */
a { color: var(--link); text-decoration: underline; text-underline-offset: .14em; text-decoration-thickness: .05em; }
a:hover { text-decoration-thickness: .11em; }
:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; }

.nl-skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: .6rem 1rem; font-family: var(--mono); font-size: .8rem;
  text-decoration: none; z-index: 2;
}
.nl-skip:focus { left: 0; }

/* ---------- masthead ---------- */
.nl-masthead { border-bottom: 1px solid var(--rule); }
.nl-masthead__inner {
  display: flex; flex-wrap: wrap; align-items: baseline;
  gap: .5rem 1.5rem; padding-top: 1.1rem; padding-bottom: 1.1rem;
}
.nl-wordmark {
  font-family: var(--mono);
  font-size: .82rem; letter-spacing: .17em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
}
.nl-wordmark span { color: var(--muted); }
.nl-wordmark:hover { text-decoration: underline; text-underline-offset: .3em; }
.nl-nav { margin-left: auto; display: flex; gap: 1.25rem; }
.nl-nav a {
  font-family: var(--mono); font-size: .78rem; letter-spacing: .05em;
  color: var(--muted); text-decoration: none;
}
.nl-nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: .3em; }
.nl-nav a[aria-current="page"] { color: var(--ink); border-bottom: 2px solid var(--bar); }

/* ---------- article ---------- */
.nl-main { padding-bottom: 4rem; }
.nl-article { padding-top: 3rem; }

.nl-pagehead { margin-bottom: 2.6rem; }
.nl-kicker {
  margin: 0 0 1rem; font-family: var(--mono);
  font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; color: var(--muted);
}
h1 {
  margin: 0;
  font-size: clamp(2.05rem, 1.55rem + 2.1vw, 2.85rem);
  font-weight: 600; line-height: 1.13; letter-spacing: -.015em;
}
.nl-standfirst {
  margin: 1.25rem 0 0; font-size: 1.1em; line-height: 1.55; color: var(--ink);
}

.nl-meta { margin: 1.9rem 0 0; padding: .9rem 0 0; border-top: 1px solid var(--rule-soft); }
.nl-meta__row { display: flex; flex-wrap: wrap; gap: .1rem .9rem; margin: 0 0 .3rem; }
.nl-meta dt {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .13em;
  text-transform: uppercase; color: var(--muted); min-width: 7.5rem; padding-top: .28rem;
}
.nl-meta dd { margin: 0; font-size: .95em; }

/* ---------- sections ---------- */
.nl-section { margin-top: 2.8rem; padding-top: 1.6rem; border-top: 1px solid var(--rule); }
.nl-section h2 {
  margin: 0 0 .9rem; font-size: 1.4rem; font-weight: 600;
  line-height: 1.25; letter-spacing: -.01em;
}
.nl-section h3 { margin: 1.8rem 0 .5rem; font-size: 1.08rem; font-weight: 600; line-height: 1.35; }
.nl-lead { margin: 0 0 1rem; color: var(--muted); }
.nl-prose > :first-child { margin-top: 0; }
.nl-prose > :last-child { margin-bottom: 0; }
p { margin: 0 0 1.05rem; }

.nl-list { margin: 0; padding: 0; list-style: none; }
.nl-list li { position: relative; padding-left: 1.4rem; margin-bottom: .85rem; }
.nl-list li::before {
  content: ""; position: absolute; left: 0; top: .72em;
  width: .55rem; height: 1px; background: var(--muted);
}
.nl-list li:last-child { margin-bottom: 0; }

.nl-note { margin: 1.2rem 0 0; font-size: .92em; color: var(--muted); }
.nl-flag {
  margin: 0 0 1.1rem; padding: .7rem .9rem;
  border-left: 3px solid var(--bar); background: var(--tint);
  font-size: .95em;
}

/* the boxed treatment, for refusals and limitations */
.nl-section--strong {
  border-top: 0; border-left: 3px solid var(--bar);
  background: var(--tint); padding: 1.5rem 1.4rem;
}

.nl-aside {
  margin-top: 2rem; padding: 1rem 1.1rem;
  border: 1px solid var(--rule); font-size: .95em; color: var(--muted);
}
.nl-aside b { color: var(--ink); }

/* ---------- the work list ---------- */
.nl-entries { margin: 0; padding: 0; list-style: none; }
.nl-entry {
  /* the status column is wide enough for "IN PREPARATION" on one line */
  display: grid; grid-template-columns: 9rem 1fr; gap: .2rem 1.25rem;
  padding: 1.1rem 0; border-top: 1px solid var(--rule-soft);
}
.nl-entry:first-child { border-top: 0; padding-top: .2rem; }
.nl-entry__when {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); padding-top: .42rem;
}
.nl-entry__title { margin: 0; font-size: 1.08rem; font-weight: 600; line-height: 1.35; }
.nl-entry__note { margin: .35rem 0 0; font-size: .95em; color: var(--muted); }

/* ---------- code ---------- */
/* ligatures off so that a double hyphen in a flag such as --json is not drawn
   as one long dash, which would read as the punctuation this house style bans */
code, .nl-pre { font-variant-ligatures: none; font-feature-settings: "calt" 0, "liga" 0; }
code { font-family: var(--mono); font-size: .86em; letter-spacing: .02em; }
.nl-pre {
  margin: 0 0 .8rem; padding: .85rem 1rem;
  background: var(--tint); border: 1px solid var(--rule-soft);
  overflow-x: auto; font-size: .82rem; line-height: 1.5;
}
.nl-pre code { font-size: inherit; }

/* ---------- placeholders, on the unpublished template ---------- */
.nl-placeholder {
  font-family: var(--mono); font-size: .8em; color: var(--muted);
  background: var(--tint); border: 1px dashed var(--rule);
  padding: .1em .35em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}

/* ---------- footer ---------- */
.nl-footer { border-top: 1px solid var(--rule); padding: 2rem 0 3.5rem; }
.nl-footer__home { margin: 0 0 1.1rem; font-size: .95em; }
.nl-footer__meta { margin: 0; padding: 0; list-style: none; font-family: var(--mono); font-size: .74rem; line-height: 1.7; color: var(--muted); }
.nl-footer__meta a { color: var(--muted); }
.nl-footer__meta a:hover { color: var(--ink); }

/* ---------- narrow ---------- */
@media (max-width: 34rem) {
  .nl-article { padding-top: 2.2rem; }
  .nl-entry { grid-template-columns: 1fr; gap: .35rem; }
  .nl-entry__when { padding-top: 0; }
  .nl-meta__row { display: block; }
  .nl-meta dt { padding-top: 0; }
  .nl-section--strong { padding: 1.2rem 1.1rem; }
}
