/* ============================================================
   DESIGN VARIABLES
   Change these to change the whole site's look. That's the point
   of keeping them at the top — no need to hunt through the file.
   ============================================================ */
:root {
  --bg: #ffffff;
  --text: #111111;
  --muted: #8a8a8a;
  --line: #ececec;
  --link: #111111;
  --link-hover: #a0a0a0;
  --link-body: #8a8a8a;
  --link-body-hover: #21cf3a;

  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-size: 14px;
  --line-height: 1.2;
  --tracking: 0.02em;

  --content-width: 680px;
  --header-width: 960px;
  --gutter: 8vw;
  --space: 1.5rem;
}

/* ============================================================
   RESET / BASE
   ============================================================ */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--font-size);
  line-height: var(--line-height);
  letter-spacing: var(--tracking);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--link-hover);
}

h1, h2, h3 {
  line-height: 1.35;
  font-weight: 500;
  font-size: 1rem;
  margin: 0 0 0.5em 0;
}

p {
  margin: 0 0 1.5em 0;
}

/* Links inside body copy (intro text, post paragraphs) get their own
   treatment — grey at rest, accent green on hover — distinct from
   nav/footer/post-list links. */
p a {
  color: var(--link-body);
}

p a:hover {
  color: var(--link-body-hover);
}

/* ============================================================
   LAYOUT
   Standard pages: centered column. The home page is the one
   exception — see ".home" below — its text column sits around
   the left third of the page instead of centered.
   ============================================================ */
.wrap {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Home page only: text stays anchored to the left edge (like the
   other pages' gutter), but the column is wider — it extends out
   to roughly the 1/3 mark of the viewport instead of stopping at
   the standard --content-width. Falls back to normal centered
   .wrap behavior on narrow screens. */
@media (min-width: 900px) {
  main.wrap.home {
    margin: 0;
    padding: 0 0 0 var(--gutter);
    max-width: clamp(420px, calc(50vw - var(--gutter)), 820px);
  }
}

/* All other main pages: left-align to match the home page instead of
   centering, but keep the standard --content-width (rather than the
   home page's wider column). Individual writing posts (.post) are
   excluded — they keep the centered article layout below. */
@media (min-width: 900px) {
  main.wrap:not(.home):not(.post) {
    margin: 0;
    padding: 0 0 0 var(--gutter);
  }
}

/* Individual writing posts: unlike the rest of the site, post content
   stays centered (the default .wrap behavior), just with a slightly
   wider text column for comfortable reading. */
@media (min-width: 900px) {
  main.wrap.post {
    max-width: 760px;
  }
}

header.site-header {
  padding: 3.5rem 0 5rem;
}

header.site-header .wrap {
  max-width: none;
  margin: 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
}

.site-name {
  font-weight: 500;
  font-size: 0.9rem;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

nav.site-nav {
  display: flex;
  gap: 1.75rem;
}

nav.site-nav a {
  font-size: 0.8rem;
  text-decoration: none;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

nav.site-nav a:hover,
nav.site-nav a.active {
  color: var(--text);
}

main {
  padding-bottom: 8rem;
}

footer.site-footer {
  padding: 4rem 0 3rem;
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
}

footer.site-footer .wrap {
  max-width: var(--header-width);
  margin: 0;
}

footer.site-footer .wrap a {
  color: var(--link-body);
}

footer.site-footer .wrap a:hover {
  color: var(--link-body-hover);
}

footer.site-footer .wrap a + a {
  margin-left: 1.5rem;
}

footer.site-footer .wrap a + a::before {
  content: "|";
  display: inline-block;
  margin-right: 1.5rem;
  color: var(--line);
}

/* ============================================================
   PAGE-LEVEL HELPERS
   Separation comes from space, not lines — no borders/dividers.
   ============================================================ */
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: 3.5rem;
}

.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.post-list li {
  padding: 1.75rem 0;
}

.post-list li:first-child {
  padding-top: 0;
}

.post-list a {
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
}

.post-date {
  display: block;
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  margin-top: 0.4rem;
}

.back-link {
  display: inline-block;
  margin-bottom: 3rem;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
}

.back-link:hover {
  color: var(--text);
}

.section-title {
  font-weight: 700;
  font-size: 0.8rem;
  line-height: 1.35;
  margin: 0 0 0.5em 0;
}

/* A section title that should read as the start of a distinct new
   section rather than a continuation of the one above it — larger
   type and extra breathing room above. */
.section-title--major {
  font-size: 1.05rem;
  font-weight: 500;
  margin-top: 3rem;
}

/* ============================================================
   GALLERY
   Bare, edge-to-edge photo grid. Breaks out of the standard
   .wrap/--gutter layout entirely — full viewport width, minimal
   gap between images, no surrounding padding.
   ============================================================ */
main.gallery-page {
  padding: 0;
  margin: 0;
  max-width: none;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(480px, 1fr));
  gap: 2px;
}

.gallery-grid img,
.gallery-grid .tile {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.gallery-grid .tile {
  background: var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
}
