/* ==========================================================================
   Ahmad Bonakdar — Urban Research and Practice
   ========================================================================== */

:root {
  --night: #0b1220;
  --night-2: #101a2d;
  --night-line: rgba(255, 255, 255, .1);
  --paper: #f6f4ef;
  --paper-2: #ebe7df;
  --ink: #151a22;
  --ink-2: #3b4350;
  --muted: #646c79;
  --muted-light: #a7b0bf;
  --rule: #d9d4c9;
  --accent: #e3a33b;
  --accent-ink: #94600f;

  /* transit line colours */
  --l1: #f2b705;
  --l2: #2e9e5b;
  --l3: #2f6fd6;
  --l4: #9b3d8f;
  --l5: #d9534f;

  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1180px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: clamp(1rem, .96rem + .2vw, 1.0625rem);
  line-height: 1.65;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--night); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: fixed;
  left: 16px; top: -60px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--night);
  font-weight: 600;
  text-decoration: none;
  transition: top .2s;
}
.skip-link:focus { top: 16px; }

.container {
  max-width: var(--max);
  margin: 0 auto;
}

/* ==========================================================================
   Shared type and components
   ========================================================================== */

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  font-family: var(--mono);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.eyebrow--light { color: var(--accent); }

.section-title {
  margin: 0 0 .5em;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 1.3rem + 2.6vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -.015em;
  font-variation-settings: 'opsz' 96;
  text-wrap: balance;
}

.section-intro {
  max-width: 60ch;
  margin: 0;
  color: var(--muted);
  font-size: 1.05em;
}

.line-badge {
  display: inline-grid;
  place-items: center;
  flex: none;
  min-width: 26px; height: 26px; padding: 0 6px;
  border-radius: 999px;
  background: var(--c, var(--l1));
  color: #fff;
  font-family: var(--sans);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: 0;
}
.eyebrow .line-badge,
.transit:first-child .line-badge { color: var(--night); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 500;
  font-size: .95rem;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .25s, border-color .25s, color .25s, transform .25s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--accent); color: var(--night); }
.btn--primary:hover { background: #f0b552; }
.btn--ghost { border-color: rgba(255, 255, 255, .35); color: #fff; }
.btn--ghost:hover { border-color: #fff; background: rgba(255, 255, 255, .06); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 2px;
  border-bottom: 1px solid currentColor;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
}
.link-arrow::after { content: "→"; transition: transform .25s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }
.link-arrow--light { color: #fff; }

/* ==========================================================================
   Header
   ========================================================================== */

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px var(--gutter);
  padding-top: max(18px, env(safe-area-inset-top));
  color: #fff;
  transition: background-color .35s, color .35s, box-shadow .35s, padding .35s;
}
.header.is-solid {
  padding-block: 12px;
  background: rgba(246, 244, 239, .92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--rule);
}

.brand {
  position: relative;
  z-index: 2;
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 500;
  letter-spacing: -.01em;
  text-decoration: none;
  white-space: nowrap;
}
.brand span { font-weight: 300; opacity: .7; }

.nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 28px);
}
.nav a {
  position: relative;
  font-size: .9rem;
  font-weight: 500;
  text-decoration: none;
  opacity: .85;
  transition: opacity .2s;
}
.nav a:not(.nav__cta)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--ease);
}
.nav a:hover, .nav a.is-current { opacity: 1; }
.nav a:hover::after, .nav a.is-current::after { transform: scaleX(1); }
.nav__cta {
  padding: 7px 16px;
  border: 1px solid currentColor;
  border-radius: 999px;
}

.menu-btn {
  display: none;
  position: relative;
  z-index: 2;
  width: 44px; height: 44px;
  margin-right: -10px;
  background: none;
  border: 0;
  cursor: pointer;
}
.menu-btn span:not(.sr-only) {
  position: absolute;
  left: 11px; right: 11px;
  height: 1.5px;
  background: currentColor;
  transition: transform .3s var(--ease), top .3s var(--ease);
}
.menu-btn span:nth-of-type(2) { top: 18px; }
.menu-btn span:nth-of-type(3) { top: 25px; }
.menu-btn[aria-expanded="true"] span:nth-of-type(2) { top: 21px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-of-type(3) { top: 21px; transform: rotate(-45deg); }

@media (max-width: 860px) {
  .menu-btn { display: block; }
  .nav {
    position: fixed;
    inset: 0;
    flex-direction: column;
    justify-content: center;
    gap: 26px;
    background: var(--night);
    color: #fff;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s, visibility .3s;
  }
  .nav a { font-family: var(--serif); font-size: 1.7rem; font-weight: 400; }
  .nav .nav__cta { font-family: var(--sans); font-size: 1rem; padding: 10px 24px; }
  .header.is-open { color: #fff; background: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .header.is-open .nav { opacity: 1; visibility: visible; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 120px var(--gutter) 150px;
  overflow: hidden;
  isolation: isolate;
  background: var(--night);
  color: #fff;
}
#city {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}
.hero::after {
  /* keeps the text legible over the skyline */
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(11, 18, 32, .8) 0%, rgba(11, 18, 32, .4) 45%, rgba(11, 18, 32, 0) 75%);
  pointer-events: none;
}

.hero__inner {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
}
.hero__inner > * {
  max-width: 640px;
  animation: rise 1s var(--ease) both;
}
.hero__inner > :nth-child(2) { animation-delay: .1s; }
.hero__inner > :nth-child(3) { animation-delay: .2s; }
.hero__inner > :nth-child(4) { animation-delay: .3s; }
.hero__inner > :nth-child(5) { animation-delay: .4s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}

.hero__title {
  margin: 0 0 24px;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(3.4rem, 2rem + 7vw, 7.2rem);
  line-height: .95;
  letter-spacing: -.03em;
  font-variation-settings: 'opsz' 144;
}
.hero__lead {
  margin: 0 0 16px;
  font-size: clamp(1.1rem, 1rem + .5vw, 1.35rem);
  line-height: 1.5;
  color: rgba(255, 255, 255, .9);
  text-wrap: pretty;
}
.hero__role {
  margin: 0 0 36px;
  font-size: .92rem;
  color: var(--muted-light);
}
.hero__role span { color: var(--accent); margin: 0 .35em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: max(28px, env(safe-area-inset-bottom));
  width: 24px; height: 40px;
  margin-left: -12px;
  border: 1.5px solid rgba(255, 255, 255, .45);
  border-radius: 12px;
}
.hero__scroll span {
  position: absolute;
  left: 50%; top: 8px;
  width: 3px; height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: #fff;
  animation: wheel 1.8s var(--ease) infinite;
}
@keyframes wheel {
  0% { opacity: 0; transform: translateY(0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translateY(12px); }
}

/* ==========================================================================
   Sections
   ========================================================================== */

.section { padding: clamp(80px, 10vw, 140px) var(--gutter); }
.section-head { margin-bottom: clamp(36px, 5vw, 64px); }
.section-head--row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 32px;
}
.section-head--row .section-title { margin-bottom: 0; }

.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: var(--delay, 0s);
}
.js .reveal.is-in { opacity: 1; transform: none; }

/* --- About ---------------------------------------------------------------- */

.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(40px, 6vw, 88px);
  align-items: start;
}
.portrait {
  position: relative;
  z-index: 0;
  max-width: 440px;
  margin: 0 18px 18px 0;
}
.portrait::before {
  /* offset frame */
  content: "";
  position: absolute;
  inset: 18px -18px -18px 18px;
  z-index: -1;
  border: 1px solid var(--rule);
}
.portrait::after {
  /* five research "lines" */
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 6px;
  background: linear-gradient(90deg, var(--l1) 0 20%, var(--l2) 20% 40%, var(--l3) 40% 60%, var(--l4) 60% 80%, var(--l5) 80%);
}
.portrait img { width: 100%; aspect-ratio: 640 / 869; object-fit: cover; }

.prose p { margin: 0 0 1.1em; max-width: 62ch; color: var(--ink-2); }
.prose a {
  color: var(--ink);
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
.prose a:hover { color: var(--accent-ink); }

.facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 36px 0 0;
  border-top: 1px solid var(--rule);
}
.facts div { padding: 18px 20px 0 0; }
.facts div + div { padding-left: 20px; border-left: 1px solid var(--rule); }
.facts dt {
  margin-bottom: 6px;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.facts dd { margin: 0; font-size: .95rem; font-weight: 500; line-height: 1.45; }

@media (max-width: 860px) {
  .about__grid { grid-template-columns: minmax(0, 1fr); }
  .portrait { max-width: 300px; }
}
@media (max-width: 600px) {
  .facts { grid-template-columns: minmax(0, 1fr); }
  .facts div, .facts div + div { padding: 14px 0; border-left: 0; border-bottom: 1px solid var(--rule); }
}

/* --- Research: transit lines ------------------------------------------------ */

.research { background: var(--night); color: #fff; }
.research .section-intro { color: var(--muted-light); }

.lines {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--night-line);
}
.transit {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
  padding: 30px 0;
  border-bottom: 1px solid var(--night-line);
}
.transit .line-badge { background: var(--c); margin-top: 2px; }
.transit__body {
  display: grid;
  grid-template-columns: minmax(200px, 4fr) minmax(0, 8fr);
  gap: 14px 40px;
  align-items: start;
}
.transit h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.35rem, 1.1rem + .8vw, 1.75rem);
  line-height: 1.2;
}

.stops {
  position: relative;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}
.stops::before {
  /* the line itself, drawn in when the row is revealed */
  content: "";
  position: absolute;
  left: 6px; right: 6px; top: 6px;
  height: 4px;
  border-radius: 4px;
  background: var(--c);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.2s var(--ease) .2s;
}
.stops li {
  position: relative;
  flex: 1 1 0;
  padding-top: 28px;
  font-size: .9rem;
  line-height: 1.4;
  color: var(--muted-light);
}
.stops li:nth-child(2) { text-align: center; }
.stops li:last-child { text-align: right; }
.stops li::before {
  content: "";
  position: absolute;
  top: 0;
  width: 16px; height: 16px;
  border: 3px solid var(--c);
  border-radius: 50%;
  background: var(--night);
}
.stops li:first-child::before { left: 0; }
.stops li:nth-child(2)::before { left: 50%; margin-left: -8px; }
.stops li:last-child::before { right: 0; }

.js .stops li { opacity: 0; transition: opacity .6s var(--ease); }
.js .stops li::before { transform: scale(0); transition: transform .5s var(--ease); }
.js .transit.is-in .stops::before,
html:not(.js) .stops::before { transform: scaleX(1); }
.js .transit.is-in .stops li { opacity: 1; }
.js .transit.is-in .stops li::before { transform: scale(1); }
.js .transit.is-in .stops li:nth-child(1), .js .transit.is-in .stops li:nth-child(1)::before { transition-delay: .3s; }
.js .transit.is-in .stops li:nth-child(2), .js .transit.is-in .stops li:nth-child(2)::before { transition-delay: .75s; }
.js .transit.is-in .stops li:nth-child(3), .js .transit.is-in .stops li:nth-child(3)::before { transition-delay: 1.2s; }

@media (max-width: 760px) {
  .transit__body { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .stops { flex-direction: column; gap: 14px; margin: 0; }
  .stops::before { left: 6px; right: auto; top: 6px; bottom: 6px; width: 4px; height: auto; transform-origin: top; }
  .js .stops::before { transform: scaleY(0); }
  .js .transit.is-in .stops::before { transform: scaleY(1); }
  .stops li, .stops li:nth-child(2), .stops li:last-child { padding: 0 0 0 30px; text-align: left; }
  .stops li::before, .stops li:nth-child(2)::before, .stops li:last-child::before { left: 0; right: auto; top: 1px; margin-left: 0; }
}

.feature {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 40px;
  margin-top: clamp(48px, 6vw, 80px);
  padding: clamp(28px, 4vw, 48px);
  border: 1px solid var(--night-line);
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(227, 163, 59, .12), transparent 55%), var(--night-2);
}
.feature > div { max-width: 640px; }
.feature h3 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 1.2rem + 1vw, 2.1rem);
  line-height: 1.2;
}
.feature p:not(.eyebrow) { margin: 0; color: var(--muted-light); }

/* --- Publications ------------------------------------------------------------ */

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}
.chip {
  padding: 8px 16px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: transparent;
  font-size: .88rem;
  font-weight: 500;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }

.pub-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--ink);
}
.pub {
  position: relative;
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 20px;
  padding: 22px 0;
  border-bottom: 1px solid var(--rule);
}
.pub::before {
  content: "";
  position: absolute;
  left: -16px; top: 0; bottom: 0;
  width: 3px;
  background: var(--accent);
  transform: scaleY(0);
  transition: transform .3s var(--ease);
}
.pub:hover::before { transform: scaleY(1); }
.pub[hidden] { display: none; }
.pub.is-entering { animation: rise .5s var(--ease) both; }
.pub__year {
  padding-top: 3px;
  font-family: var(--mono);
  font-size: .95rem;
  color: var(--accent-ink);
}
.pub a {
  font-family: var(--serif);
  font-size: clamp(1.08rem, 1rem + .3vw, 1.25rem);
  line-height: 1.35;
  text-decoration: none;
  font-variation-settings: 'opsz' 24;
  background: linear-gradient(var(--accent), var(--accent)) 0 100% / 0 1.5px no-repeat;
  transition: background-size .4s var(--ease);
}
.pub a::after { content: " ↗"; font-family: var(--sans); font-size: .8em; color: var(--muted); }
.pub a:hover { background-size: 100% 1.5px; }
.pub p { margin: 6px 0 0; font-size: .9rem; color: var(--muted); }
.pub b { font-weight: 600; color: var(--ink-2); }
.pub i { color: var(--ink-2); }

@media (max-width: 600px) {
  .pub { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .pub::before { left: -12px; }
}

/* --- Writing ------------------------------------------------------------------ */

.writing { background: var(--paper-2); }
.posts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
  gap: 20px;
}
.post {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 28px;
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: 6px;
  text-decoration: none;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s, opacity .8s var(--ease);
}
.post:hover {
  transform: translateY(-4px);
  border-color: transparent;
  box-shadow: 0 18px 40px rgba(21, 26, 34, .1);
}
.post time {
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.post h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.22rem;
  line-height: 1.3;
}
.post p { margin: 0; font-size: .92rem; color: var(--muted); }
.post::after {
  content: "Read on Homeless Hub →";
  margin-top: auto;
  padding-top: 10px;
  font-size: .85rem;
  font-weight: 500;
}

/* --- Photography ------------------------------------------------------------- */

.photos { background: var(--night); color: #fff; }
.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.shot {
  display: block;
  position: relative;
  aspect-ratio: 3 / 2;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 3px;
  background: #000;
  overflow: hidden;
  cursor: zoom-in;
}
.shot:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
@media (max-width: 760px) {
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .shot:first-child, .shot:last-child { grid-column: span 2; grid-row: auto; aspect-ratio: 3 / 2; }
}
.shot img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.shot::after {
  content: attr(data-caption);
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 36px 14px 12px;
  background: linear-gradient(transparent, rgba(0, 0, 0, .72));
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .06em;
  text-align: left;
  color: #fff;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .35s, transform .35s var(--ease);
}
.shot:hover img, .shot:focus-visible img { transform: scale(1.04); }
.shot:hover::after, .shot:focus-visible::after { opacity: 1; transform: none; }
@media (hover: none) {
  .shot::after { opacity: 1; transform: none; }
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 64px;
  align-items: center;
  padding: 24px 8px;
  background: rgba(5, 8, 14, .95);
  color: #fff;
  animation: fade .25s ease;
}
.lightbox[hidden] { display: none; }
@keyframes fade { from { opacity: 0; } }
.lightbox figure { display: grid; justify-items: center; gap: 14px; margin: 0; }
.lightbox img {
  width: auto;
  max-height: calc(100vh - 120px);
  max-height: calc(100svh - 120px);
  border-radius: 2px;
}
.lightbox figcaption { font-family: var(--mono); font-size: .8rem; letter-spacing: .06em; color: var(--muted-light); }
.lightbox button {
  background: none;
  border: 0;
  color: #fff;
  opacity: .7;
  cursor: pointer;
  transition: opacity .2s;
}
.lightbox button:hover { opacity: 1; }
.lightbox__nav { height: 100%; font-size: 3rem; line-height: 1; }
.lightbox__close { position: absolute; top: 12px; right: 16px; font-size: 2.4rem; line-height: 1; }
@media (max-width: 600px) {
  .lightbox { grid-template-columns: 40px minmax(0, 1fr) 40px; padding: 16px 0; }
}

/* --- Contact ---------------------------------------------------------------- */

.contact {
  padding-block: clamp(64px, 8vw, 112px);
  background: var(--night-2);
  color: #fff;
}
.contact .section-intro { color: var(--muted-light); }
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px clamp(40px, 6vw, 96px);
  align-items: end;
}
.contact__mail {
  display: inline-block;
  margin-bottom: 28px;
  padding-bottom: 4px;
  font-family: var(--serif);
  font-size: clamp(1.2rem, .8rem + 1.5vw, 2rem);
  text-decoration: none;
  overflow-wrap: break-word;
  background: linear-gradient(var(--accent), var(--accent)) 0 100% / 100% 2px no-repeat;
}
.contact__mail:hover { color: var(--accent); }
.contact__links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.contact__links .link-arrow { font-size: .92rem; border-bottom-color: rgba(255, 255, 255, .3); }
@media (max-width: 760px) {
  .contact__grid { grid-template-columns: minmax(0, 1fr); }
}

/* --- Footer -------------------------------------------------------------------- */

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 24px var(--gutter);
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  background: var(--night-2);
  border-top: 1px solid var(--night-line);
  font-size: .85rem;
  color: var(--muted-light);
}
.footer p { margin: 0; }
.footer a { text-decoration: none; }
.footer a:hover { color: #fff; }

/* --- 404 ---------------------------------------------------------------------- */

.lost {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-content: center;
  justify-items: start;
  gap: 18px;
  padding: var(--gutter);
  background: var(--night);
  color: #fff;
}
.lost h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  line-height: 1.05;
}
.lost p:not(.eyebrow) { margin: 0 0 12px; max-width: 46ch; color: var(--muted-light); }

/* --- Reduced motion ------------------------------------------------------------ */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    transition-delay: 0s !important;
  }
}

/* hover lift has to beat the reveal transform */
.js .post.reveal.is-in:hover { transform: translateY(-4px); }

/* small tiles on phones are too tight for captions; the lightbox shows them */
@media (max-width: 760px) {
  .shot:not(:first-child):not(:last-child)::after { display: none; }
}
