@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo.woff2") format("woff2-variations"), url("/fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --foam: #f3f4f2;      /* polystyrene white */
  --graphite: #2a2c30;  /* pencil */
  --grey: #6d7177;      /* secondary text (AA on foam) */
  --rule: #d6d8d4;
  --cobalt: #2440c8;    /* sign paint */
  --cobalt-deep: #172a8a;
  --gap: clamp(12px, 1.6vw, 22px);
  --pad: clamp(16px, 4vw, 56px);
  color-scheme: light;
}

@property --depth {
  syntax: "<number>";
  inherits: true;
  initial-value: 1;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--foam);
  color: var(--graphite);
  font: 400 1rem/1.5 "Archivo", system-ui, sans-serif;
  font-stretch: 100%;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--cobalt); outline-offset: 3px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--graphite); color: var(--foam); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* Masthead */
.masthead { padding: clamp(28px, 6vw, 80px) var(--pad) clamp(20px, 3vw, 36px); }
.masthead.compact { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; padding-block: 22px; border-bottom: 1px solid var(--rule); }

/* The extruded sign: the one loud thing on the site */
.wordmark { margin: 0; line-height: .86; }
.wordmark a {
  --c: var(--cobalt);
  display: inline-block;
  text-decoration: none;
  color: #fff;
  font-weight: 900;
  font-stretch: 125%;
  font-size: clamp(3.1rem, 12.5vw, 10.5rem);
  letter-spacing: -.02em;
  -webkit-text-stroke: .012em var(--graphite);
  paint-order: stroke fill;
  text-shadow:
    calc(var(--depth) * .010em) calc(var(--depth) * .010em) 0 var(--c),
    calc(var(--depth) * .020em) calc(var(--depth) * .020em) 0 var(--c),
    calc(var(--depth) * .030em) calc(var(--depth) * .030em) 0 var(--c),
    calc(var(--depth) * .040em) calc(var(--depth) * .040em) 0 var(--c),
    calc(var(--depth) * .050em) calc(var(--depth) * .050em) 0 var(--c),
    calc(var(--depth) * .060em) calc(var(--depth) * .060em) 0 var(--cobalt-deep),
    calc(var(--depth) * .068em) calc(var(--depth) * .068em) 0 var(--cobalt-deep);
  padding-right: .08em;
  animation: extrude 1.1s cubic-bezier(.2, .8, .2, 1) .15s both;
}
.wordmark a:hover { --c: #3352e0; }
.wordmark.small a { font-size: clamp(1.6rem, 4.4vw, 2.4rem); animation: none; }
@keyframes extrude { from { --depth: 0; } to { --depth: 1; } }

.intro { max-width: 34em; margin: clamp(18px, 2.6vw, 34px) 0 0; font-size: clamp(1.05rem, 1.6vw, 1.3rem); line-height: 1.45; }
.section { margin: 18px 0 0; font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 750; font-stretch: 112%; letter-spacing: -.01em; }

nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 22px; }
.masthead > nav { margin-top: clamp(18px, 2.4vw, 30px); }
.masthead.compact > nav { margin-top: 0; }
nav a { text-decoration: none; font-weight: 550; padding: 6px 0; display: inline-block; border-bottom: 2px solid transparent; }
nav a:hover { border-color: var(--rule); }
nav a[aria-current="page"] { border-color: var(--cobalt); color: var(--cobalt); }

/* Gallery: photos at their natural proportions */
.grid { --row: clamp(170px, 22vw, 290px); list-style: none; margin: 0; padding: 0 var(--pad) 64px; display: flex; flex-wrap: wrap; gap: calc(var(--gap) * 1.6) var(--gap); }
.grid::after { content: ""; flex-grow: 999; }
.tile { flex: var(--ar) 1 calc(var(--ar) * var(--row)); min-width: 0; }
.tile img { aspect-ratio: var(--ar); object-fit: cover; }
.tile > a { display: block; text-decoration: none; }
.tile img { width: 100%; background: var(--rule); }
.tile .cap { display: block; margin-top: 8px; font-weight: 600; line-height: 1.3; }
.tile > a:hover .cap { color: var(--cobalt); text-decoration: underline; text-underline-offset: 3px; }
.tile .meta { display: block; color: var(--grey); font-size: .875rem; margin-top: 2px; }

/* Post */
.post { padding: clamp(20px, 4vw, 48px) var(--pad) 64px; max-width: 1180px; margin: 0 auto; }
.hero { margin: 0 auto; }
.hero.tall { max-width: 640px; }
.hero img { width: auto; max-height: 80vh; margin-inline: auto; }
.zoom { display: block; cursor: zoom-in; }
.post .text { max-width: 640px; margin: 22px auto 0; }
.hero.wide + .text { max-width: none; }
.post h1 { margin: 0; font-size: clamp(1.6rem, 3.2vw, 2.6rem); line-height: 1.12; font-weight: 750; font-stretch: 108%; letter-spacing: -.012em; max-width: 26ch; }
.post .meta { margin: 10px 0 0; color: var(--grey); }
.post .meta a { color: var(--cobalt); }
.more { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--gap); margin-top: 40px; }
.more figure { margin: 0; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--rule); }
.pager a { text-decoration: none; font-weight: 600; line-height: 1.3; }
.pager a span { display: block; color: var(--grey); font-weight: 400; font-size: .875rem; margin-bottom: 4px; }
.pager a:hover { color: var(--cobalt); }
.pager .newer { text-align: right; }

/* Plain pages */
.prose { padding: clamp(28px, 5vw, 64px) var(--pad) 80px; max-width: calc(36em + 2 * var(--pad)); font-size: 1.125rem; line-height: 1.6; }
.prose h1 { font-size: clamp(1.8rem, 3.6vw, 2.8rem); font-stretch: 112%; font-weight: 750; margin: 0 0 18px; }
.prose a { color: var(--cobalt); }

.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 22px var(--pad) 30px; border-top: 1px solid var(--rule); color: var(--grey); font-size: .875rem; }
.foot p { margin: 0; }

/* Lightbox */
dialog.lb { padding: 0; border: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
dialog.lb::backdrop { background: rgba(26, 27, 30, .94); }
dialog.lb img { width: auto; height: auto; max-width: 96vw; max-height: 92vh; margin: 4vh auto 0; cursor: zoom-out; }
dialog.lb button { position: fixed; top: 14px; right: 16px; font: 600 1rem "Archivo", sans-serif; color: #fff; background: none; border: 2px solid rgba(255, 255, 255, .5); padding: 6px 14px; cursor: pointer; }

@media (max-width: 560px) {
  .grid { --row: 46vw; }
  .pager { grid-template-columns: 1fr; }
  .pager .newer { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  .wordmark a { animation: none; }
}
