/* soft sharp edges — shared stylesheet. Every page links to this one file. */

@font-face {
  font-family: "Fraunces";
  src: url("assets/fonts/fraunces-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("assets/fonts/fraunces-latin-wght-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --bg: #f6f5f2;
  --ink: #1b1a19;
  --muted: #6b6762;
  --line: #d9d6d0;
  --accent: #1b1a19;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --measure: 38rem;
  --gutter: clamp(1.25rem, 5vw, 3rem);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151413;
    --ink: #eeebe6;
    --muted: #9a958e;
    --line: #34312e;
    --accent: #eeebe6;
  }
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.7;
}

a { color: inherit; text-underline-offset: 0.25em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }

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

.skip {
  position: absolute; left: -999px; top: 0;
  background: var(--ink); color: var(--bg); padding: 0.5rem 1rem; z-index: 10;
}
.skip:focus { left: 0; }

/* ---------- header / nav ---------- */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  padding: 1.5rem var(--gutter);
}
.wordmark {
  font-family: var(--serif);
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
}
.nav { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.nav a {
  font-size: 0.9375rem;
  color: var(--muted);
  text-decoration: none;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
}
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }

/* ---------- main ---------- */
main { flex: 1; padding: 0 var(--gutter); }

/* title page */
.hero {
  min-height: 62vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  max-width: 60rem;
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.75rem, 11vw, 7rem);
  line-height: 1;
  letter-spacing: -0.03em;
  margin: 0 0 1.5rem;
  font-variation-settings: "opsz" 144;
}
.hero .byline { margin: 0; color: var(--muted); }
.hero .byline span { display: block; }

/* text pages */
.page { max-width: var(--measure); padding: 2rem 0 4rem; }
.page h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2rem, 6vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 2rem;
}
.page p { margin: 0 0 1.4em; }
.page .lede { font-family: var(--serif); font-size: 1.25rem; line-height: 1.6; }

/* contact */
.contact-list { list-style: none; padding: 0; margin: 2rem 0 0; border-top: 1px solid var(--line); }
.contact-list li {
  display: flex; gap: 1.5rem; padding: 1rem 0; border-bottom: 1px solid var(--line);
}
.contact-list .label { width: 6rem; flex: none; color: var(--muted); font-size: 0.9375rem; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- gallery (work.html) ---------- */
.gallery { padding: 1rem 0 4rem; }
.grid {
  list-style: none; padding: 0; margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}
.grid a { text-decoration: none; display: block; }
.grid figure { margin: 0; }
.grid img {
  display: block; width: 100%; height: auto;
  aspect-ratio: 3 / 4; object-fit: cover;   /* even thumbnails; full image shows on each piece's page */
  background: #000; transition: opacity 0.2s;
}
.grid a:hover img { opacity: 0.85; }
.grid figcaption { font-family: var(--serif); font-size: 1rem; margin-top: 0.75rem; }

/* ---------- single piece (work-01.html etc.) ---------- */
.work { max-width: 70rem; padding: 0 0 4rem; }
.work .back { display: inline-block; font-size: 0.9375rem; color: var(--muted); text-decoration: none; margin-bottom: 1.5rem; }
.work .back:hover { color: var(--ink); }
.work img {
  display: block;
  width: auto; height: auto;
  max-width: 100%;
  max-height: 85vh;      /* tall scans fit on screen */
  background: #000;
}
.work h1 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  line-height: 1.2;
  margin: 1.5rem 0 0.25rem;
}
.work .meta { color: var(--muted); font-size: 0.9375rem; margin: 0; }

/* desktop: details sit to the right of the image, whole image fits on screen */
@media (min-width: 56rem) {
  .work {
    display: grid;
    grid-template-columns: auto minmax(14rem, 20rem);
    column-gap: clamp(2rem, 4vw, 4rem);
    align-items: end;
    justify-content: start;
  }
  .work .back { grid-column: 1 / -1; justify-self: start; }
  .work img { max-height: calc(100vh - 11rem); max-height: calc(100dvh - 11rem); }
  .work .details { padding-bottom: 0.25rem; }
  .work h1 { margin-top: 0; }
}

/* ---------- footer ---------- */
.site-footer {
  padding: 2rem var(--gutter);
  color: var(--muted);
  font-size: 0.8125rem;
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- landing page with full-bleed Scan 41 ---------- */
.home {
  --ink: #f3efe9;
  --muted: rgba(243, 239, 233, 0.72);
  --accent: #f3efe9;
  background:
    linear-gradient(100deg, rgba(0,0,0,0.72) 0%, rgba(0,0,0,0.35) 45%, rgba(0,0,0,0) 75%),
    #000 url("images/home-scan41.jpg") 65% 35% / cover no-repeat;
  color: var(--ink);
}
.home .hero { min-height: 70vh; }
.home .hero h1 { text-shadow: 0 2px 24px rgba(0,0,0,0.5); }
.home .site-footer { color: var(--muted); }
@media (max-width: 40rem) {
  .home {
    background:
      linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.15) 22%, rgba(0,0,0,0.5) 55%, rgba(0,0,0,0.8) 100%),
      #000 url("images/home-scan41.jpg") 50% 30% / cover no-repeat;
  }
  .home .hero { justify-content: flex-end; padding-bottom: 2rem; }
}
