/* Public site. Monochrome, taken from the tones of the landing photograph.
   Type: Andale Mono throughout (built into Macs; other devices use the closest monospace they have). */
:root {
  --ground: #121212;   /* matches the Lightroom embed background */
  --raised: #1b1b1a;
  --paper: #e9e7e2;
  --dim: #9b9993;
  --rule: #2c2c2a;
  --measure: 40rem;
  --page: 74rem;
  --gutter: clamp(1rem, 4vw, 3rem);
  --mono: 'Andale Mono', AndaleMono, Menlo, Consolas, 'Liberation Mono', monospace;
  --thin: 400;
  --text: 400;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--ground); color: var(--paper);
  font-family: var(--mono); font-weight: 400; font-size: .9375rem; line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--paper); outline-offset: 4px; }
img { display: block; max-width: 100%; }

/* ---------- Landing ---------- */
.hero { position: relative; height: 100svh; min-height: 30rem; overflow: hidden; background: #000; }
.hero picture, .hero img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero img { object-fit: cover; object-position: 50% 38%; }
.hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(0,0,0,.72) 0%, rgba(0,0,0,.25) 32%, rgba(0,0,0,0) 55%);
}
.hero-text { position: absolute; z-index: 1; left: var(--gutter); right: var(--gutter); bottom: clamp(1.5rem, 6vh, 4rem); }
.name {
  margin: 0; font-family: var(--mono); font-weight: 400; line-height: 1.05; letter-spacing: 0;
  font-size: clamp(1.5rem, 4.125vw, 3.75rem); max-width: 20ch; text-wrap: balance;
}
.tagline { margin: .9rem 0 0; font-family: var(--mono); font-style: normal; font-weight: 400; font-size: clamp(1.1rem, 1.8vw, 1.45rem); color: var(--paper); opacity: .8; }
.hero-skip {
  position: absolute; z-index: 1; right: var(--gutter); bottom: clamp(1.5rem, 6vh, 4rem);
  font-size: 1rem; color: var(--paper); opacity: .85;
}
.hero-skip:hover { opacity: 1; }

/* The one moment of motion: the photograph surfaces out of black like a print in the tray. */
@media (prefers-reduced-motion: no-preference) {
  .hero img { animation: develop 2.2s cubic-bezier(.2,.6,.2,1) both; }
  .hero-text, .hero-skip { animation: surface 1.2s ease-out 1.4s both; }
  @keyframes develop { from { opacity: 0; filter: brightness(.4) contrast(1.3); } to { opacity: 1; filter: none; } }
  @keyframes surface { from { opacity: 0; } to { opacity: 1; } }
}

/* ---------- Stories index ---------- */
main { padding: 0 var(--gutter); }
.stories, .about { max-width: var(--page); margin: 0 auto; }
.stories { padding: clamp(3.5rem, 10vh, 7rem) 0 2rem; }
.section-h { margin: 0 0 1.5rem; font-size: 1rem; font-weight: var(--text); color: var(--dim); }
.index { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--rule); }
.entry {
  display: grid; grid-template-columns: minmax(8rem, 14rem) 1fr; column-gap: 2rem;
  padding: 1.75rem 0 1.9rem; border-top: 1px solid var(--rule); text-decoration: none;
}
.entry-meta { grid-row: 1 / span 2; padding-top: .9rem; font-size: 1rem; color: var(--dim); }
.entry-title {
  font-weight: var(--thin); font-size: clamp(2rem, 4.6vw, 3.6rem); line-height: 1.05; letter-spacing: 0;
  text-wrap: balance;
}
.entry-excerpt { margin-top: .75rem; max-width: var(--measure); color: var(--dim); font-size: 1.0625rem; line-height: 1.55; }
.entry:hover .entry-title, .entry:focus-visible .entry-title { font-style: italic; }
.entry:hover .entry-excerpt { color: var(--paper); }
.empty { color: var(--dim); font-style: italic; padding: 2rem 0; border-top: 1px solid var(--rule); margin: 0; }

.about { display: grid; grid-template-columns: minmax(8rem, 14rem) 1fr; column-gap: 2rem; padding: 3rem 0 1rem; }
.about .section-h { padding-top: .3rem; }

.prose { max-width: var(--measure); }
.prose p { margin: 0 0 1.1em; }
.prose p:last-child { margin-bottom: 0; }

/* ---------- Story page ---------- */
.topbar {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
  padding: 1.25rem var(--gutter); font-size: 1rem;
}
.topbar a { text-decoration: none; color: var(--dim); }
.topbar a:hover { color: var(--paper); }
.topbar .home-link { color: var(--paper); font-size: 1.25rem; }
.story-top {
  max-width: var(--page); margin: 0 auto; padding: clamp(2.5rem, 9vh, 6rem) 0 clamp(3rem, 9vh, 5.5rem);
  display: grid; grid-template-columns: 1fr 1fr; column-gap: clamp(2rem, 5vw, 5rem); align-items: start;
}
.story-head { grid-column: 1; align-self: center; }
.story-intro { grid-column: 2; }
.story-top:not(:has(.story-intro)) .story-head { grid-column: 1 / -1; }
.story-title {
  margin: 0; font-weight: var(--thin); font-size: clamp(2.4rem, 4.8vw, 4rem); line-height: 1.05;
  letter-spacing: 0; max-width: 14ch; text-wrap: balance;
}
.story-meta { margin: .9rem 0 0; color: var(--dim); font-size: 1rem; }
.story-intro p { max-width: var(--measure); }

/* Photos: three to a row. Each sits in a 3:2 cell, uncropped; wide photos fill it, upright ones sit centred. */
.photos {
  max-width: var(--page); margin: 0 auto clamp(4rem, 12vh, 8rem);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(.625rem, 1.5vw, 1.5rem) clamp(1rem, 2.5vw, 2.5rem);
}
.photo { margin: 0; }
.photo img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; object-position: 50% 50%; }

.album { margin: 0 calc(-1 * var(--gutter)); }
.album-frame {
  position: relative; width: 100%; height: 100svh; background: var(--ground);
}
.album-frame::before {
  content: 'Loading photographs…'; position: absolute; inset: 0; display: grid; place-items: center;
  color: var(--dim); font-style: italic; font-size: 1rem;
}
.album-frame iframe { position: relative; width: 100%; height: 100%; border: 0; display: block; }
.album figcaption { max-width: calc(var(--page) + 2 * var(--gutter)); margin: 1rem auto 0; padding: 0 var(--gutter); font-size: 1rem; color: var(--dim); }
.album figcaption a:hover { color: var(--paper); }

.pager {
  max-width: var(--page); margin: clamp(3rem, 10vh, 6rem) auto 0;
  display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; border-top: 1px solid var(--rule); padding-top: 1.5rem;
}
.pager a { text-decoration: none; font-size: clamp(1.3rem, 2.4vw, 1.8rem); font-weight: var(--thin); line-height: 1.15; }
.pager a span { display: block; font-size: 1rem; color: var(--dim); margin-bottom: .35rem; font-weight: var(--text); }
.pager a:hover { font-style: italic; }
.pager-next { text-align: right; }

.notfound { max-width: var(--page); margin: 0 auto; padding: 6rem 0; }
.notfound p { color: var(--dim); }

.foot {
  max-width: calc(var(--page) + 2 * var(--gutter)); margin: 0 auto; padding: 4rem var(--gutter) 2.5rem;
  font-size: .9375rem; color: var(--dim);
}

@media (max-width: 40rem) {
  .entry, .about, .story-top { grid-template-columns: 1fr; }
  .story-intro { grid-column: 1; margin-top: 2rem; }
  .entry-meta { grid-row: auto; padding: 0 0 .35rem; }
  .photos { grid-template-columns: repeat(2, 1fr); }
  .pager { grid-template-columns: 1fr; }
  .pager-next { text-align: left; }
  .hero-skip { display: none; }
}
