/* IBM Plex, self-hosted. SIL Open Font License 1.1.
   Sans is a variable font (400-600 in one file); Mono ships static weights.
   Subsets: latin and latin-ext, so the browser fetches only what a page needs. */

@font-face{
  font-family:'IBM Plex Sans';
  font-style:normal;
  font-weight:400 600;
  font-display:swap;
  src:url('/fonts/ibm-plex-sans-var-latin.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;
}
@font-face{
  font-family:'IBM Plex Sans';
  font-style:normal;
  font-weight:400 600;
  font-display:swap;
  src:url('/fonts/ibm-plex-sans-var-latin-ext.woff2') format('woff2');
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face{
  font-family:'IBM Plex Sans';
  font-style:italic;
  font-weight:400;
  font-display:swap;
  src:url('/fonts/ibm-plex-sans-400-italic-latin.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;
}
@font-face{
  font-family:'IBM Plex Sans';
  font-style:italic;
  font-weight:400;
  font-display:swap;
  src:url('/fonts/ibm-plex-sans-400-italic-latin-ext.woff2') format('woff2');
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face{
  font-family:'IBM Plex Mono';
  font-style:normal;
  font-weight:400;
  font-display:swap;
  src:url('/fonts/ibm-plex-mono-400-latin.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;
}
@font-face{
  font-family:'IBM Plex Mono';
  font-style:normal;
  font-weight:400;
  font-display:swap;
  src:url('/fonts/ibm-plex-mono-400-latin-ext.woff2') format('woff2');
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face{
  font-family:'IBM Plex Mono';
  font-style:normal;
  font-weight:500;
  font-display:swap;
  src:url('/fonts/ibm-plex-mono-500-latin.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;
}
@font-face{
  font-family:'IBM Plex Mono';
  font-style:normal;
  font-weight:500;
  font-display:swap;
  src:url('/fonts/ibm-plex-mono-500-latin-ext.woff2') format('woff2');
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* corveye.com — words on a page.

   Three palettes: Wing, Rubric, Ink. A short script in <head> picks one per
   visit and stamps it on <html> as data-palette, where it stays for the rest
   of that visit. With JavaScript off, the bare :root below applies and the
   site is Ink.

   Each palette shifts five values, not just the accent — the paper, ink,
   muted text and rules all carry a trace of the same hue. That is what stops
   it reading as grey with a coloured link stuck on.

   Order matters: every light value first, then every dark value inside the
   media query. Equal specificity, so the later rule wins in dark mode. */

:root{
  --sans:"IBM Plex Sans",ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  --mono:"IBM Plex Mono",ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;

  --measure:34rem;

  /* Wing — the oily green in a crow's wing, and the no-JavaScript default. */
  --paper:#F9FAF7;
  --ink:#171A17;
  --muted:#666C65;
  --rule:#E0E5DE;
  --rule-soft:#EBEFE9;
  --accent:#1E5140;
}

/* Wing — the oily green in a crow's wing. */
:root[data-palette="wing"]{
  --paper:#F9FAF7;
  --ink:#171A17;
  --muted:#666C65;
  --rule:#E0E5DE;
  --rule-soft:#EBEFE9;
  --accent:#1E5140;
}

/* Rubric — oxblood, the red of printed marginalia. */
:root[data-palette="rubric"]{
  --paper:#FAF9F5;
  --ink:#1A1917;
  --muted:#6E6A62;
  --rule:#E5DFDC;
  --rule-soft:#EFEAE6;
  --accent:#7A2231;
}

:root[data-palette="ink"]{
  --paper:#FAF9F5;
  --ink:#1A1917;
  --muted:#6E6A62;
  --rule:#E2DED4;
  --rule-soft:#EDEAE2;
  --accent:#1F3A5F;
}

@media (prefers-color-scheme:dark){
  :root{
    --paper:#151815;
    --ink:#E4E9E3;
    --muted:#848B83;
    --rule:#2A312A;
    --rule-soft:#202620;
    --accent:#74C6A4;
  }
  :root[data-palette="wing"]{
    --paper:#151815;
    --ink:#E4E9E3;
    --muted:#848B83;
    --rule:#2A312A;
    --rule-soft:#202620;
    --accent:#74C6A4;
  }
  :root[data-palette="rubric"]{
    --paper:#181616;
    --ink:#E9E4E2;
    --muted:#8C8683;
    --rule:#302B2B;
    --rule-soft:#25211F;
    --accent:#E08A96;
  }
  :root[data-palette="ink"]{
    --paper:#17171A;
    --ink:#E8E4DC;
    --muted:#8B8780;
    --rule:#2C2C31;
    --rule-soft:#232327;
    --accent:#9BBBE8;
  }
}

*{box-sizing:border-box}

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

body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:var(--sans);
  font-size:1.0625rem;
  line-height:1.7;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}

img,video{max-width:100%;height:auto}

a:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:1px}

.wrap{
  max-width:var(--measure);
  margin:0 auto;
  padding:0 clamp(1rem,5vw,1.5rem);
}

/* ---------- masthead ---------- */

.masthead{
  display:flex;
  flex-wrap:wrap;
  align-items:baseline;
  gap:.75rem 1.5rem;
  padding:3rem 0 0;
}

.wordmark{
  font-family:var(--mono);
  font-weight:600;
  font-size:.9375rem;
  letter-spacing:.02em;
  color:var(--accent);
  text-decoration:none;
}

.masthead nav{
  display:flex;
  gap:1.15rem;
  margin-left:auto;
  font-family:var(--mono);
  font-size:.75rem;
  letter-spacing:.06em;
}

.masthead nav a{
  color:var(--muted);
  text-decoration:none;
  padding-bottom:2px;
  border-bottom:1px solid transparent;
}
.masthead nav a:hover{color:var(--ink);border-bottom-color:var(--ink)}
.masthead nav a[aria-current]{color:var(--ink);border-bottom-color:var(--ink)}

/* ---------- intro ---------- */

.intro{padding:2.25rem 0 0;max-width:30rem}
.intro p{margin:0;color:var(--muted)}
.intro p + p{margin-top:.9rem}
.intro strong{color:var(--ink);font-weight:600}
.intro a{color:var(--accent)}

/* ---------- the archive ---------- */

.year{
  display:flex;
  align-items:baseline;
  gap:1rem;
  margin:2.75rem 0 .25rem;
  font-family:var(--mono);
  font-size:.6875rem;
  font-weight:500;
  letter-spacing:.14em;
  color:var(--muted);
  font-variant-numeric:tabular-nums;
}
.year::after{content:"";flex:1;height:1px;background:var(--rule)}

.archive{list-style:none;margin:2.25rem 0 0;padding:0}
.year + .archive{margin-top:0}
.archive li{border-bottom:1px solid var(--rule-soft)}

.archive a{
  display:grid;
  grid-template-columns:4.25rem 1fr;
  gap:0 1rem;
  align-items:baseline;
  padding:.72rem 0;
  text-decoration:none;
  color:inherit;
}

.archive .d{
  font-family:var(--mono);
  font-size:.6875rem;
  letter-spacing:.04em;
  color:var(--muted);
  font-variant-numeric:tabular-nums;
  white-space:nowrap;
}

.archive .t{
  font-size:1rem;
  line-height:1.45;
  text-wrap:balance;
}

.archive a:hover .t{
  color:var(--accent);
  text-decoration:underline;
  text-underline-offset:3px;
  text-decoration-thickness:1px;
}
.archive a:hover .d{color:var(--ink)}

/* Portrait on the about page. Widen the cap if the photo wants more room. */
.flat img{
  display:block;
  max-width:min(100%,18rem);
  margin:0 0 1.75rem;
  border-radius:2px;
}

/* ---------- article ---------- */

article{padding:2.5rem 0 0}

.kicker{
  margin:0 0 1.1rem;
  font-family:var(--mono);
  font-size:.6875rem;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--muted);
  font-variant-numeric:tabular-nums;
}

.draftflag{
  margin:0 0 1.25rem;
  padding:.5rem .75rem;
  border:1px dashed var(--rule);
  border-radius:2px;
  font-family:var(--mono);
  font-size:.6875rem;
  letter-spacing:.1em;
  text-transform:uppercase;
  color:var(--muted);
}

article h1{
  margin:0 0 1.9rem;
  font-size:clamp(1.5rem,4.5vw,1.9rem);
  line-height:1.2;
  font-weight:600;
  letter-spacing:-.012em;
  text-wrap:balance;
}

article p{margin:0 0 1.35rem}

article h2{
  margin:2.4rem 0 1rem;
  font-size:1.125rem;
  font-weight:600;
  line-height:1.4;
  letter-spacing:-.005em;
}
article h3{
  margin:2rem 0 .8rem;
  font-size:1rem;
  font-weight:600;
  line-height:1.45;
}

article a{
  color:var(--accent);
  text-decoration:underline;
  text-underline-offset:2.5px;
  text-decoration-thickness:1px;
}

article ul,article ol{margin:0 0 1.35rem;padding-left:1.3rem}
article li{margin:0 0 .45rem}
article li::marker{color:var(--muted)}

article blockquote{
  margin:1.9rem 0;
  padding-left:1.15rem;
  border-left:2px solid var(--rule);
  color:var(--muted);
}
article blockquote p:last-child{margin-bottom:0}

article hr{
  height:1px;
  border:0;
  background:var(--rule);
  margin:2.5rem 0;
}

article code{
  font-family:var(--mono);
  font-size:.875em;
  background:var(--rule-soft);
  padding:.1em .35em;
  border-radius:2px;
}

article pre{
  margin:0 0 1.35rem;
  padding:1rem;
  overflow-x:auto;
  background:var(--rule-soft);
  border-radius:2px;
  font-size:.8125rem;
  line-height:1.65;
}
article pre code{background:none;padding:0;font-size:inherit}

.tablewrap,article table{display:block;overflow-x:auto}
article table{
  width:100%;
  border-collapse:collapse;
  margin:0 0 1.35rem;
  font-size:.9375rem;
}
article th,article td{
  text-align:left;
  padding:.5rem .75rem .5rem 0;
  border-bottom:1px solid var(--rule-soft);
}
article th{
  font-family:var(--mono);
  font-size:.6875rem;
  font-weight:500;
  letter-spacing:.08em;
  text-transform:uppercase;
  color:var(--muted);
}

/* ---------- references ---------- */

.refs{margin:3.25rem 0 0;padding-top:1.1rem;border-top:1px solid var(--rule)}
.refs h2{
  margin:0 0 .7rem;
  font-family:var(--mono);
  font-size:.6875rem;
  font-weight:500;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--muted);
}
.refs p,.refs ul{margin:0 0 .4rem;font-size:.9375rem;line-height:1.6}
.refs ul{list-style:none;padding:0}
.refs li{margin:0 0 .4rem}
.refs a{color:var(--accent)}

/* ---------- post navigation ---------- */

.postnav{
  display:flex;
  justify-content:space-between;
  gap:1.5rem;
  margin:2.5rem 0 0;
  padding-top:1.1rem;
  border-top:1px solid var(--rule);
  font-family:var(--mono);
  font-size:.75rem;
  letter-spacing:.03em;
}
.postnav a{color:var(--muted);text-decoration:none;max-width:45%}
.postnav a:hover{color:var(--ink)}
.postnav a.right{text-align:right}
.postnav .lbl{
  display:block;
  font-size:.6875rem;
  letter-spacing:.1em;
  text-transform:uppercase;
  opacity:.65;
  margin-bottom:.25rem;
}

/* ---------- flat pages (about, books, 404) ---------- */

.flat{padding:2.5rem 0 0}
.flat h1{
  margin:0 0 1.5rem;
  font-size:clamp(1.5rem,4.5vw,1.9rem);
  line-height:1.2;
  font-weight:600;
  letter-spacing:-.012em;
  text-wrap:balance;
}
.flat h2{
  margin:2.5rem 0 .3rem;
  font-size:1.125rem;
  font-weight:600;
  line-height:1.35;
}
.flat h2 + p em{color:var(--muted);font-style:normal}
.flat h3{margin:2rem 0 .5rem;font-size:1rem;font-weight:600}
.flat p{margin:0 0 1.35rem}
.flat a{
  color:var(--accent);
  text-decoration:underline;
  text-underline-offset:2.5px;
  text-decoration-thickness:1px;
}
.flat hr{
  height:1px;
  border:0;
  background:var(--rule-soft);
  margin:2.25rem 0;
}
.flat ul{margin:0 0 1.35rem;padding-left:1.3rem}
.flat li{margin:0 0 .45rem}
.flat li::marker{color:var(--muted)}

/* ---------- footer ---------- */

footer.site{
  max-width:var(--measure);
  margin:4rem auto 0;
  padding:3.5rem clamp(1rem,5vw,1.5rem) 4.5rem;
  border-top:1px solid var(--rule);
  font-family:var(--mono);
  font-size:.6875rem;
  letter-spacing:.05em;
  color:var(--muted);
  display:flex;
  flex-wrap:wrap;
  gap:.5rem 1.25rem;
}
footer.site a{
  color:var(--muted);
  display:inline-flex;
  align-items:center;
  gap:.45em;
}
footer.site a:hover{color:var(--ink)}
footer.site .spacer{flex:1}

/* Inline SVG, so it takes the link's colour in every palette and both themes
   and costs no extra request. Sized in em to track the footer type. */
footer.site .icon{
  width:1.05em;
  height:1.05em;
  flex:none;
}

/* ---------- small screens ---------- */

@media (max-width:32rem){
  .archive a{grid-template-columns:1fr;gap:.15rem}
  .archive .d{font-size:.625rem}
  .masthead nav{margin-left:0;width:100%}
  .postnav{flex-direction:column;gap:1rem}
  .postnav a{max-width:100%}
  .postnav a.right{text-align:left}
}

@media print{
  .masthead nav,.postnav,footer.site{display:none}
  body{background:#fff;color:#000}
}
