/* ============================================
   Ellen Warfield — site styling
   ============================================ */

:root {
  --ink: #111;
  --muted: #8a8a8a;
  --bg: #fff;
  --gutter: 32px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }


html.snap { scroll-snap-type: y proximity; }

body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px var(--gutter);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--bg);
}
.site-header .brand { font-size: 20px; font-weight: 500; letter-spacing: 0.1em; line-height: 1; }
.site-header nav a { margin-left: 28px; }
.site-header a:hover { opacity: 0.55; }

/* On the home page the header floats over the photos */
.home .site-header {
  background: transparent;
  color: #fff;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.35);
}

/* ---------- Home: full-screen photos ---------- */
.feature {
  position: relative;
  display: block;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: #eee;
  scroll-snap-align: start;
}
.feature img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.4s ease;
}
.feature:hover img { transform: scale(1.015); }

.feature-caption {
  position: absolute;
  left: var(--gutter);
  bottom: 28px;
  color: #fff;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.35);
}
.feature-caption .view {
  display: block;
  margin-top: 4px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.4s, transform 0.4s;
}
.feature:hover .feature-caption .view { opacity: 0.85; transform: none; }

/* ---------- Footer ---------- */
.site-footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding: 40px var(--gutter);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  scroll-snap-align: end;
}
.site-footer a:hover { color: var(--ink); }

/* ---------- Project page ---------- */
.project {
  max-width: 1440px;
  margin: 0 auto;
  padding: 150px var(--gutter) 40px;
}
.project-head { max-width: 620px; margin-bottom: 48px; }
.project-head h1 {
  font-size: 26px;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.project-head .category {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}
.project-head .intro { color: #555; margin-top: 18px; }

/* Photo grid: rows fit together, nothing is cropped */
.grid {
  --row: 300px;
  --gap: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: var(--gap);
}
.grid::after { content: ""; flex-grow: 999999; } /* last row doesn't stretch */
.tile {
  position: relative;
  display: block;
  overflow: hidden;
  background: #f2f2f2;
  cursor: zoom-in;
}
.tile i { display: block; }
.tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s;
}
.tile:hover img { opacity: 0.85; }

/* Big photo viewer */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 64px 72px;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  cursor: pointer;
}
.lightbox button {
  position: absolute;
  background: none;
  border: 0;
  font: inherit;
  color: var(--ink);
  cursor: pointer;
  padding: 16px;
}
.lightbox button:hover { opacity: 0.5; }
.lb-close { top: 8px; right: 16px; font-size: 12px !important; letter-spacing: 0.12em; text-transform: uppercase; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); font-size: 26px !important; }
.lb-prev { left: 8px; }
.lb-next { right: 8px; }
.lb-count {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.story-text {
  max-width: 620px;
  margin: 40px 0;
  font-size: 18px;
  line-height: 1.65;
}

.next-project {
  display: block;
  margin-top: 120px;
  padding-top: 32px;
  border-top: 1px solid #e8e8e8;
}
.next-project .label {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.next-project .title { font-size: 26px; margin-top: 6px; }
.next-project:hover .title { opacity: 0.55; }

/* ---------- Contact page ---------- */
.contact {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 1440px;
  margin: 0 auto;
  padding: 140px var(--gutter) 80px;
}
.contact .category {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
}
.contact .email {
  font-size: clamp(26px, 5vw, 56px);
  letter-spacing: -0.02em;
  line-height: 1.1;
  word-break: break-word;
}
.contact .email:hover { opacity: 0.55; }
.contact .extra { margin-top: 20px; color: #555; }
.contact .bio { max-width: 560px; margin-top: 56px; color: #555; }
.contact .clients { margin-top: 56px; }
.contact .clients ul {
  list-style: none;
  columns: 3 200px;
  column-gap: 32px;
  max-width: 760px;
}
.contact .clients li { padding: 3px 0; break-inside: avoid; }
.contact .pubs { max-width: 760px; }

/* ---------- Phones ---------- */
@media (max-width: 700px) {
  :root { --gutter: 18px; }
  .site-header { padding: 18px var(--gutter); }
  .site-header nav a { margin-left: 16px; }
  .site-header .brand { font-size: 15px; letter-spacing: 0.08em; }
  .project { padding-top: 110px; }
  .project-head { margin-bottom: 44px; }
  .grid { --row: 150px; --gap: 6px; }
  .lightbox { padding: 56px 8px; }
  .lb-prev, .lb-next { display: none; }
  .feature-caption .view { opacity: 0.85; transform: none; }
}
