/* Maya Fielding website
   Ground linen, ink charcoal. 80 px margins at 1440, 8 px unit, 16 px gutter, square corners.
   Values from the brand book tokens: the linen palette, adopted November 9, 2026. */

:root {
  --ground: #fffaf3;     /* linen */
  --ink: #333439;
  --muted: #66625b;
  --stone: #e8e1d8;      /* light field: mats, the map's land */
  --lavender: #bdb6d9;   /* lavender dust, the accent: one mark per page at most; here, the office on the map */
  --ash: #ab9a95;        /* ash brown, mid field: image placeholders; on the map, projects under construction, with a charcoal ring */
  --umber: #5c4d48;      /* dark field, warm */
  --pine: #616965;       /* dark field, green; never with umber */
  --rule: rgba(51, 52, 57, 0.10);
  --display: 'Maya Fielding Display', 'Stoned Youth', 'Helvetica Neue', Arial, sans-serif;
  --text: 'Hanken Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --sketch-opacity: 0.30;   /* the background drawing; raise toward 0.45 if it reads too faint */
  color-scheme: light;
}

@font-face {
  font-family: 'Maya Fielding Display';
  src: url('../fonts/MayaFieldingDisplay-Regular.otf') format('opentype');
  font-weight: 400; font-style: normal; font-display: block;
}

* { box-sizing: border-box; }
/* the scrollbar's room is always kept, so a short page and a long one put everything in the same place */
html { height: auto; scrollbar-gutter: stable; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font-family: var(--text); font-size: 16px; line-height: 1.5; font-weight: 400;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--muted); }
a:focus-visible { outline: 1px solid var(--ink); outline-offset: 4px; }

/* ---- sheet ---- */
.page { position: relative; z-index: 1; max-width: 1440px; margin: 0 auto; }
.wrap {
  padding-left: max(16px, env(safe-area-inset-left, 0px), 5.5vw);
  padding-right: max(16px, env(safe-area-inset-right, 0px), 5.5vw);
}
@media (min-width: 1440px) { .wrap { padding-left: 80px; padding-right: 80px; } }
.line { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--rule); pointer-events: none; }
@media (max-width: 800px) { .line { display: none; } }

/* ---- header ---- */
header.top { display: flex; justify-content: space-between; align-items: center; height: 80px; }
header.top svg { width: 208px; height: 40px;  /* viewBox trimmed to the letters so the M sits on the column edge */ display: block; flex: none; fill: var(--ink); }
/* phones: the wordmark keeps its size; the navigation drops to its own line under it */
@media (max-width: 600px) {
  header.top { height: auto; flex-wrap: wrap; row-gap: 12px; padding-block: 20px 16px; }
  header.top nav { width: 100%; gap: 24px; }
}
nav { display: flex; gap: 32px; font-size: 14px; line-height: 20px; }

/* ---- type ---- */
h1, h2 { margin: 0; font-family: var(--display); font-weight: 400; text-transform: uppercase; text-wrap: balance; }
/* page title matches the wordmark: its capitals are 19.8 px tall at 228 px wide; the display face's capitals are 0.7 em */
h1 { font-size: 28px; line-height: 32px; letter-spacing: 0.5px; }
h2 { font-size: 22px; line-height: 24px; letter-spacing: 0.5px; }
.meta { margin: 0; font-size: 13px; line-height: 20px; color: var(--muted); }
.meta.right { text-align: right; }
.cap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; line-height: 20px; color: var(--muted); }
.cap p { margin: 0; }

/* ---- background sketch (project pages) ---- */
#sketch { position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: var(--sketch-opacity); mix-blend-mode: multiply; }
#sketch canvas { display: block; width: 100%; height: 100%; }

/* ---- hero ---- */
.hero { padding-bottom: 40px; display: flex; flex-direction: column; gap: 24px; }
.heroimg { margin: 0; width: 100%; aspect-ratio: 1800 / 1208; max-height: calc(100vh - 160px); overflow: hidden; background: var(--stone); }
.heroimg img { width: 100%; height: 100%; object-fit: cover; }
.herorow { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.titleblock { display: flex; flex-direction: column; gap: 12px; max-width: 520px; }
.titleblock .meta { font-size: 14px; }

/* ---- hero gallery ----
   One slide per screen, snaps on swipe. Photos and renders fill the frame (.photo);
   drawings sit whole on the ground (.drawing). */
.gallery { display: flex; flex-direction: column; gap: 12px; outline: none; }
.gallery:focus-visible .track { outline: 1px solid var(--ink); outline-offset: 4px; }
.track {
  display: flex; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scrollbar-width: none; -ms-overflow-style: none;
}
.track::-webkit-scrollbar { display: none; }
/* every image is shown whole at its own proportion, centred in the frame on the ground; a slide of
   two narrow images sets them side by side with the 16 px gutter */
.slide { margin: 0; flex: 0 0 100%; min-width: 0; scroll-snap-align: start; aspect-ratio: 1800 / 1208; max-height: calc(100vh - 200px);
  background: var(--ground); display: flex; justify-content: center; align-items: center; gap: 16px; }
.slide img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; min-width: 0; }
/* a pair: both images at one height, the smaller of the frame's height and the height at which the pair fills its width */
.slide.two { container-type: inline-size; }
.slide.two img { flex: none; width: auto; max-width: none; max-height: none; height: min(100%, calc((100cqw - 16px) / var(--r))); }
.slide .mat { height: 100%; aspect-ratio: auto; }
.gbar { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.gnav { display: flex; align-items: center; gap: 16px; font-size: 13px; line-height: 20px; color: var(--muted); font-variant-numeric: tabular-nums; }
.gnav button {
  appearance: none; border: 0; background: none; padding: 0; margin: 0; cursor: pointer;
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; color: var(--ink);
}
.gnav button:hover { color: var(--muted); }
.gnav button:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; }
.gnav svg { width: 24px; height: 24px; display: block; }
@media (prefers-reduced-motion: reduce) { .track { scroll-behavior: auto; } }

/* ---- collage ----
   The sheets hang on a spine: a vertical line at a place fixed for each project (--spine, set
   on the element from SPINE in make.py). Figures alternate sides with one edge on the spine,
   the two sides run as independent columns, and the right one starts lower so they interleave.
   Captions read toward the spine. Phones stack the figures in their original order. */
.collage { padding-top: 96px; padding-bottom: 96px; }
.spine { display: grid; grid-template-columns: minmax(0, var(--spine, 50%)) minmax(0, 1fr); column-gap: 16px; align-items: start; }
.spine .side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.spine .side.l { align-items: flex-end; }
.spine .side.r { align-items: flex-start; padding-top: 120px; }
.collage figure { margin: 0; min-width: 0; max-width: 100%; position: relative; }
.collage figure.wide { width: min(100%, 560px); }
.collage figure.square { width: min(100%, 420px); }
.collage figure.tall { width: min(100%, 340px); }
/* the caption floats on the image, no box: placed where it reads with the most contrast and set in
   charcoal, or linen where the image is dark there (positions from _build/place_captions.py) */
@font-face { font-family: 'Maya Fielding Display'; src: url('../fonts/MayaFieldingDisplay-Thin.otf') format('opentype'); font-weight: 250; font-display: block; }
@font-face { font-family: 'Maya Fielding Display'; src: url('../fonts/MayaFieldingDisplay-Bold.otf') format('opentype'); font-weight: 700; font-display: block; }
@font-face { font-family: 'Jacob Kanner'; src: url('../fonts/JacobKanner-Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; }
.collage figcaption.float { position: absolute; top: var(--t); left: var(--l); width: var(--w); max-width: calc(100% - 24px); margin: 0;
  font-family: 'Jacob Kanner', var(--text); font-size: 12px; line-height: 15px; word-spacing: 0.2em; color: var(--ink); }
.collage figcaption.float.ground { color: var(--ground); }

.collage figure > img { width: 100%; }
.collage figure.band { width: 100%; margin-top: 96px; }
.collage figure.band.plan { max-width: 880px; margin-left: auto; margin-right: auto; }
.facts { margin-top: 96px; display: flex; flex-wrap: wrap; gap: 16px; }
/* phones keep the spine: two columns at the project's spine, every figure the full width of its side,
   8 px between figures and across the spine; captions shrink to fit */
@media (max-width: 800px) {
  .collage { padding-top: 48px; padding-bottom: 48px; }
  .spine { column-gap: 8px; }
  .spine .side { gap: 8px; }
  .spine .side.r { padding-top: 48px; }
  .collage figure, .collage figure.wide, .collage figure.square, .collage figure.tall, .collage figure.narrow { width: 100%; }
  /* drawings stay small on phones: a tall plan is capped at about a third of the screen's height */
  .collage figure.sketch > img { max-height: 36vh; width: auto; max-width: 100%; }
  .spine .side.l figure.sketch > img { margin-left: auto; }
  .collage figcaption.float { font-size: 10px; line-height: 12px; word-spacing: 0.15em; top: var(--tm); left: var(--lm); width: var(--wm); max-width: calc(100% - 16px); color: var(--ink); }
  .collage figcaption.float.m-ground { color: var(--ground); }
  .collage figcaption.float.m-hide { display: none; }
  .facts { margin-top: 48px; }
  .collage figure.band { margin-top: 48px; }
}

/* placeholder mats until real images go in */
.mat {
  width: 100%; aspect-ratio: 4 / 3; padding: 24px;
  display: flex; align-items: center; justify-content: center; text-align: center;
  font-size: 13px; line-height: 20px; color: var(--muted);
}
.mat.stone { background: var(--stone); }
.mat.ash { background: var(--ash); color: var(--ink); }
.mat.portrait { aspect-ratio: 3 / 4; }
.mat.square { aspect-ratio: 1; }

/* the blank band where the background drawing finishes; nothing goes in it */
.sketch-room { height: max(60vh, 520px); }
/* after a closing drawing the sketch finishes over its lower edge, overlapping it (Christopher, November 12, 2026, Boothbay) */
.band + .sketch-room { margin-top: -200px; height: 440px; }
/* phones: a shorter band for the scroll drawing to finish in, so it does not read as an empty gap */
@media (max-width: 600px) { .sketch-room { height: 200px; } .band + .sketch-room { margin-top: -90px; height: 220px; } }

/* the landing sheet (retired November 5, 2026; kept for reference) */
.sketch-final { grid-column: 8 / span 5; margin-top: 160px; }
.sketch-final img { opacity: 0; width: 100%; mix-blend-mode: multiply; }
.sketch-final.landed img { opacity: 1; }
.sketch-final .cap { opacity: 0; transition: opacity 0.3s; }
.sketch-final.landed .cap { opacity: 1; }
@media (max-width: 800px) { .sketch-final { grid-column: 1 / -1; margin-top: 0; } }
@media (prefers-reduced-motion: reduce) { .sketch-final img, .sketch-final .cap { opacity: 1; } }

/* plans stacked as one set */
.plans { display: flex; flex-direction: column; gap: 12px; }

/* facts */
.facts dl { margin: 0; flex: 1 1 400px; min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; font-size: 14px; line-height: 20px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.facts .body { margin: 0; flex: 1 1 400px; min-width: 0; font-size: 16px; line-height: 24px; font-weight: 300; max-width: 60ch; }

/* ---- home index ---- */
.index { padding-top: 80px; padding-bottom: 80px; display: flex; flex-direction: column; gap: 96px; }
.index article { display: flex; flex-direction: column; gap: 16px; }
.index .head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
/* the first project name and its images, and CONTACT and the headshots, sit at exactly the same place:
   the title row is one fixed 20 px line, whatever the fonts measure */
.index article:first-child .head, .contact.trial > .head { height: 20px; align-items: flex-start; flex-wrap: nowrap; }
.index article:first-child .head .meta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 20px; }
.index .pair { display: flex; gap: 16px; align-items: flex-start; }
.index .pair > * { flex: 1 1 400px; min-width: 0; }
.index .pair > img { height: auto; width: 0; }
/* phones: a pair stacks, each image full width */
/* phones keep each project's two images side by side at one shared height, so the work list stays short (November 9, 2026) */
@media (max-width: 600px) { .index .pair { gap: 8px; } .index { gap: 56px; } }

/* ---- footer ---- */
footer { padding-top: 32px; padding-bottom: 40px; }
footer .rule { height: 1px; background: var(--ink); margin-bottom: 24px; }
footer .cols { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; line-height: 20px; color: var(--muted); }
footer p { margin: 0; flex: 1 1 240px; min-width: 0; }
footer p.right { text-align: right; flex: 1 1 200px; }
footer strong { font-weight: 400; color: var(--ink); }

/* ---- map, home page footer ----
   NYC shoreline drawn from the city's borough boundaries; pins are placed by neighborhood, never by address. */
.mapblock { margin-top: 48px; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 24px 40px; align-items: end; }
.nycmap { display: block; width: 100%; max-width: 260px; height: auto; overflow: hidden; }
.nycmap .land { fill: var(--stone); stroke: var(--ink); stroke-width: 0.5px; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.nycmap .pin.build { fill: var(--ash); stroke: var(--ink); stroke-width: 1px; vector-effect: non-scaling-stroke; }
.nycmap .pin.done { fill: var(--ink); }
.nycmap .pin.office { fill: var(--lavender); stroke: var(--ink); stroke-width: 0.75px; vector-effect: non-scaling-stroke; stroke-linejoin: miter; }
/* a project pin turns lavender under the cursor, so it reads as a link */
.nycmap a { cursor: pointer; }
.nycmap a .pin { transition: fill 0.2s ease; }
.nycmap a:hover .pin, .nycmap a:focus-visible .pin { fill: var(--lavender); }
.nycmap text { font-family: var(--text); font-size: 13px; fill: var(--ink); }
.nycmap a:hover text, .nycmap a:focus text { text-decoration: underline; }
.maplegend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 13px; line-height: 20px; color: var(--ink); }
.maplegend li { display: flex; align-items: center; gap: 10px; }
.maplegend i { width: 11px; height: 11px; border-radius: 50%; flex: none; }
.maplegend .build { background: var(--ash); box-shadow: inset 0 0 0 1px var(--ink); }
.maplegend .done { background: var(--ink); }
.maplegend .xmark { width: 13px; height: 13px; flex: none; fill: var(--lavender); stroke: var(--ink); stroke-width: 0.75px; vector-effect: non-scaling-stroke; }
.maplegend .note { color: var(--muted); }
@media (max-width: 800px) { .mapblock { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) { #sketch { display: none; } }

/* ---- contact page ----
   the founders side by side; names stacked one word per line, the middle name in Bold (brand book chapter 3) */
.contact { padding-top: 40px; padding-bottom: 24px; }
.contact .people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 16px; margin-top: 40px; max-width: 880px; }
.person figure { margin: 0; aspect-ratio: 4 / 5; max-width: 100%; }
.person figure img, .person figure .mat { width: 100%; height: 100%; object-fit: cover; display: block; }
.person .name { margin-top: 16px; }
.person .name { font-weight: 400; }
.person .name b { font-weight: 700; }   /* only the middle name in Bold */
/* contact: first and last names in Thin, the middle names in Regular */
.contact .name { font-weight: 250; }
.contact .name b { font-weight: 400; }
/* the two founders face each other across the gutter: the first reads right, toward the second */
.contact .people .person:first-child { text-align: right; }
@media (max-width: 600px) { .contact .people .person:first-child { text-align: left; } }
.person p { margin: 8px 0 0; font-size: 14px; line-height: 20px; }
.person .role { color: var(--muted); }
.person a { color: var(--ink); }
.contact .studio { margin-top: 56px; font-size: 14px; line-height: 20px; }
.contact .studio strong { font-weight: 400; }
.contact .mapblock { margin-top: 24px; }
@media (max-width: 600px) { .contact .people { grid-template-columns: 1fr; } }
/* the wordmark as the studio's entry in the map legend: letters at the legend's cap height */
.maplegend .studio-mark svg:not(.xmark) { width: 109px; height: 19px; display: block; fill: var(--ink); margin-left: -2px; }
/* a drawing on the home page sits on the ground: its sheet is transparent (white removed on export) */
/* a photograph with its drawing laid over its right edge: the photo takes 60 percent, the drawing
   (transparent sheet) starts inside it and sits lower, so the lines cross onto the photo */
.index .pair.overlap { display: grid; grid-template-columns: repeat(20, minmax(0, 1fr)); gap: 0; }
.index .pair.overlap > img:first-child { grid-column: 1 / 13; grid-row: 1; }
.index .pair.overlap > img.drawing { grid-column: 10 / 21; grid-row: 1; align-self: start; margin-top: 8%; position: relative; z-index: 1; }
@media (max-width: 600px) {
  .index .pair.overlap > img:first-child { grid-column: 1 / 17; }
  .index .pair.overlap > img.drawing { grid-column: 6 / 21; grid-row: 2; margin-top: -18%; }
}
.collage figure.narrow { width: min(100%, 220px); }
/* a project with one image on the home page: it keeps the width of half a pair */
.index .pair > :only-child { flex: 0 1 calc(50% - 8px); }
@media (max-width: 832px) { .index .pair > :only-child { flex-basis: 100%; } }

/* ---- contact: founders either side of the map, centred on the photos; legend under the map ---- */
.contact.trial .triad { display: grid; grid-template-columns: minmax(0, 1fr) minmax(200px, 260px) minmax(0, 1fr); column-gap: 16px; row-gap: 16px; margin-top: 40px; margin-bottom: 40px; }
.contact.trial .face { margin: 0; aspect-ratio: 4 / 5; }
.contact.trial .face img { width: 100%; height: 100%; object-fit: cover; display: block; }
.contact.trial .face.l { grid-column: 1; grid-row: 1; } .contact.trial .face.r { grid-column: 3; grid-row: 1; }
.contact.trial .mapcol { grid-column: 2; grid-row: 1; align-self: center; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.contact.trial .who.l { grid-column: 1; grid-row: 2; text-align: right; } .contact.trial .who.r { grid-column: 3; grid-row: 2; }
.contact.trial .gap { display: none; }
.contact.trial > .head h1 { font-size: 18px; line-height: 20px; letter-spacing: 0.5px; }   /* the same size as the project names on the work list */
/* CONTACT and the photos sit where the first project name and its images sit on the work list, so nothing jumps between pages */
.contact.trial { padding-top: 80px; }
.contact.trial .triad { margin-top: 16px; }
.contact.trial .mapcol .nycmap { max-width: 100%; }
.contact.trial .mapcol .studio { margin: 8px 0 0; text-align: center; font-size: 14px; line-height: 20px; }
.contact.trial .mapcol .maplegend { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 4px 16px; font-size: 12px; }
.contact.trial .mapcol .maplegend .studio-mark svg:not(.xmark) { width: 86px; height: 15px; }
.contact.trial .who p { margin: 8px 0 0; font-size: 14px; line-height: 20px; }
.contact.trial .who .role { color: var(--muted); }
.contact.trial .who a { color: var(--ink); }
@media (max-width: 800px) {
  .contact.trial .triad { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .contact.trial .face.r { grid-column: 2; } .contact.trial .who.r { grid-column: 2; }
  .contact.trial .mapcol { grid-column: 1 / -1; grid-row: 3; padding-top: 32px; }
  .contact.trial .mapcol .nycmap { max-width: 260px; }
}
@media (max-width: 600px) {
  .contact.trial .triad { grid-template-columns: minmax(0, 1fr); }
  .contact.trial .face.l { grid-row: 1; } .contact.trial .who.l { grid-column: 1; grid-row: 2; text-align: left; margin-bottom: 24px; }
  .contact.trial .face.r { grid-column: 1; grid-row: 3; } .contact.trial .who.r { grid-column: 1; grid-row: 4; }
  .contact.trial .mapcol { grid-column: 1; grid-row: 5; }
}

/* ---- coming soon band: top of a project page with little to show yet ----
   Umber field, linen type in the display face, capitals, scrolling slowly. Holds still for reduced motion. */
.soon { background: var(--umber); color: var(--ground); overflow: hidden; height: clamp(280px, 52vh, 520px);
  display: flex; align-items: center; margin-bottom: 16px; }
.soon .soon-track { display: flex; flex: none; white-space: nowrap; animation: soon 48s linear infinite; }
.soon .soon-track span { font-family: var(--display); text-transform: uppercase; font-weight: 400;
  font-size: 104px; line-height: 108px; letter-spacing: 2px; padding-right: 0.9em; }
@keyframes soon { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (max-width: 600px) { .soon { height: 240px; } .soon .soon-track span { font-size: 56px; line-height: 60px; letter-spacing: 1px; } }
@media (prefers-reduced-motion: reduce) { .soon .soon-track { animation: none; } }
.pair .soon { height: auto; aspect-ratio: 3 / 2; flex: 1 1 0; margin: 0; }
.pair .soon .soon-track span { font-size: 44px; line-height: 48px; letter-spacing: 1px; }

/* callouts are one or two words: each sizes to its own text and never wraps */
.collage figcaption.float { width: max-content; white-space: nowrap; }

/* project names on the home page sit a step below the wordmark (was 22/24, November 9, 2026) */
.index .head h2 { font-size: 18px; line-height: 20px; letter-spacing: 0.5px; }

/* ---- coming soon on the work list: a small strip scrolling along the bottom of the images ----
   Always linen. Still for reduced motion. */
.index .soon-pair { position: relative; overflow: hidden; }
.soon-strip { position: absolute; left: 0; right: 0; bottom: 12px; overflow: hidden; pointer-events: none; color: var(--ground); }
.soon-strip .soon-track { display: flex; flex: none; white-space: nowrap; animation: soon 60s linear infinite; }
.soon-strip .soon-track span { font-family: var(--display); text-transform: uppercase; font-size: 18px; line-height: 20px; letter-spacing: 1px; padding-right: 2em; }
@media (prefers-reduced-motion: reduce) { .soon-strip .soon-track { animation: none; } }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* every project on the work page sits in the same frame: full column width, 12:5; images fill it (cover crop).
   Phones keep the stack, each image full width at its own shape. */
@media (min-width: 601px) {
  .index .pair { aspect-ratio: 12 / 5; min-height: 0; overflow: hidden; align-items: stretch; }
  .index .pair > img { height: 100%; min-height: 0; object-fit: cover; }
}

/* phones: a callout never runs past the image's right edge; it wraps instead */
@media (max-width: 600px) { .collage figcaption.float { white-space: normal; max-width: calc(100% - var(--lm) - 6px); } }

/* phones: the header links get a taller hit area without moving the type */
@media (max-width: 600px) { header.top nav a, .index .head h2 a, a[href^="mailto:"] { display: inline-block; padding: 12px 0; margin: -12px 0; } }

/* =====================================================================
   PHONE LAYOUT (preview branch phone-layout, November 9, 2026)
   Phones only (600 px and below, side lines from 800 px). Laptops unchanged.
   ===================================================================== */

/* side lines on phones too: they sit on the content edge and frame the images, as on a laptop */
@media (max-width: 800px) { .line { display: block; } }
/* phones (upright or turned sideways) and tablets: the lines sit 16 px inside the content edge,
   as they do on a wide screen, not on the image edge */
@media (max-width: 1024px) {
  .line[style*="left"] { left: calc(max(16px, 5.5vw) + 16px) !important; }
  .line[style*="right"] { right: calc(max(16px, 5.5vw) + 16px) !important; }
}

@media (max-width: 600px) {
  /* header on one line: the wordmark scales a little so Work and Contact fit beside it */
  header.top { flex-wrap: nowrap; height: 64px; padding-block: 0; row-gap: 0; }
  header.top svg { width: clamp(150px, 50vw, 208px); height: auto; }
  header.top nav { width: auto; gap: 20px; }

  /* work list: one image per project, full width, every project in the same 3:2 frame */
  .index .pair, .index .pair.overlap { display: block; aspect-ratio: auto; }
  .index .pair > img ~ img { display: none; }
  .index .pair > img:first-of-type { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
  .index .pair.overlap > img:first-child { grid-column: auto; }
  .soon-strip { bottom: 10px; }
  .soon-strip .soon-track span { font-size: 14px; line-height: 16px; }

  /* gallery: a paired slide fills the slide's height, the two images side by side and cropped,
     so every slide is the same size */
  .slide.two { gap: 8px; }
  .slide.two img { height: 100%; width: calc(50% - 4px); max-width: none; object-fit: cover; }

  /* collage: one column in the project's own order, every image full width */
  .spine { display: flex; flex-direction: column; gap: 16px; }
  .spine .side { display: contents; }
  .spine figure[style*="--mo"] { order: var(--mo) !important; }   /* a project's own phone order (phone_order) */
  .spine .side.r { padding-top: 0; }
  .collage figure.sketch > img, .spine .side.l figure.sketch > img { max-height: 56vh; margin-left: 0; }
  /* callouts at their laptop size and place, all of them shown */
  .collage figcaption.float, .collage figcaption.float.m-hide {
    display: block; font-size: 12px; line-height: 15px; word-spacing: 0.2em;
    top: var(--t); left: var(--l); width: max-content; white-space: nowrap; max-width: calc(100% - var(--l) - 6px); color: var(--ink); }
  .collage figcaption.float.ground { color: var(--ground); }

  /* contact: the two founders side by side, as on a laptop; the map under them */
  .contact.trial .triad { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 8px; }
  .contact.trial .face.l { grid-column: 1; grid-row: 1; } .contact.trial .face.r { grid-column: 2; grid-row: 1; }
  .contact.trial .who.l { grid-column: 1; grid-row: 2; text-align: right; margin-bottom: 0; } .contact.trial .who.r { grid-column: 2; grid-row: 2; }
  .contact.trial .who .name { font-size: 18px; line-height: 20px; }
  .contact.trial .who p { font-size: 13px; }
  /* a long address breaks only after the @ (the pages put a <wbr> there) */
  .contact.trial .mapcol { grid-column: 1 / -1; grid-row: 3; padding-top: 32px; }

  /* COMING SOON moves at the laptop's pace: the phone strip is shorter, so it runs in half the time */
  .soon-strip .soon-track { animation-duration: 28s; }

  /* exterior renders: the crop keeps the top of the building */
  /* the same sky above each roof as on Classon: the roofline just inside the top of the frame */
  .index img[src*="classon-avenue/img/street"] { object-position: 50% 0%; }
  .index img[src*="west-122nd/img/facade"] { object-position: 50% 28%; }
  .index img[src*="jackson-street/img/facade"] { object-position: 50% 38%; }

  /* footer: the studio email sits under the address, on the same left edge */
  footer p.right { text-align: left; flex-basis: 100%; }

  /* contact: each founder's email on one line, scaled to the column */
  .contact.trial .who a[href^="mailto:"] { white-space: nowrap; font-size: min(12px, 3.05vw); }
}


/* Carbon "learn more" overlay (assets/js/carbon.js, November 12, 2026). Linen ground, charcoal ink; the bars in
   pine (stored) and charcoal (released), as on the diagram. Square corners. */
.collage figure.has-carbon > img { cursor: pointer; }
html.carbon-open, html.carbon-open body { overflow: hidden; }
/* floats in front of the page (Christopher and Emily, November 12, 2026): the page stays visible, dimmed, around it */
#carbon { position: fixed; inset: 0; z-index: 50; background: rgba(51, 52, 57, 0.32); display: flex; align-items: center; justify-content: center; padding: 48px; }
#carbon[hidden] { display: none; }
.carbon-panel { position: relative; width: 100%; max-width: 1120px; max-height: 100%; overflow-y: auto; -webkit-overflow-scrolling: touch;
  background: var(--ground); padding: 0 48px 48px; box-shadow: 0 24px 64px rgba(51, 52, 57, 0.18); }
.collage figure.has-carbon { position: relative; }
/* floats just over the bottom of the diagram, in its right column, above the footnote (--hb set per page) */
.carbon-hint { position: absolute; left: 56.5%; bottom: var(--hb, 6%); display: block; margin: 0; padding: 0; border: 0; background: none; color: var(--ink); font: inherit;
  font-size: 11px; line-height: 16px; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: underline;
  text-underline-offset: 3px; cursor: pointer; }
.carbon-hint:hover { color: var(--muted); }
.carbon-head { display: flex; align-items: baseline; gap: 16px; position: sticky; top: 0; background: var(--ground); padding: 16px 0; z-index: 2; }
.carbon-head h2 { font-size: 44px; line-height: 48px; letter-spacing: 1px; }
.carbon-head .meta { flex: 1; }
.carbon-close { margin-left: auto; width: 44px; height: 44px; border: 0; background: none; color: var(--ink); cursor: pointer; display: flex; align-items: center; justify-content: center; align-self: center; }
.carbon-close:hover { color: var(--muted); }
.carbon-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 64px; align-items: start; margin-top: 24px; }
.carbon-draw { position: sticky; top: 96px; width: fit-content; max-width: 100%; }  /* hugs the image, so the tap areas sit on it */
.carbon-draw img { display: block; width: auto; max-width: 100%; max-height: calc(100vh - 240px); }
.carbon-spot { position: absolute; border: 0; padding: 0; background: transparent; cursor: pointer; }
/* no zones drawn (Christopher, November 12, 2026): the tap areas are invisible; the chosen assembly gets the
   diagram's own mark, a small charcoal square at its middle */
.carbon-spot::after { content: ''; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -4px; background: var(--ink); opacity: 0; transition: opacity 120ms; }
.carbon-spot.on.first::after { opacity: 1; }   /* one mark per assembly, on its first area */
.carbon-spot:focus-visible { outline: 1px dotted var(--muted); }
.carbon-net { margin: 0; font-size: 56px; line-height: 64px; font-weight: 300; letter-spacing: -0.5px; }
.carbon-lead { margin: 16px 0 24px; font-size: 16px; line-height: 24px; font-weight: 300; max-width: 60ch; }
.carbon-bar { display: flex; height: 24px; }
.carbon-bar .st, .carbon-mini .st { background: var(--pine); }
.carbon-bar .re, .carbon-mini .re { background: var(--ink); }
.carbon-legend { display: flex; justify-content: space-between; margin-top: 8px; font-size: 14px; line-height: 20px; font-weight: 500; font-variant-numeric: tabular-nums; }
.carbon-side h3 { margin: 48px 0 4px; font-size: 16px; line-height: 24px; font-weight: 500; }
.carbon-list { margin-top: 16px; border-top: 1px solid var(--ink); }
.carbon-row { border-bottom: 1px solid var(--stone); }
.carbon-rowhead { width: 100%; display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto; gap: 8px 16px; padding: 16px 0;
  border: 0; background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.carbon-rowhead .n { font-size: 16px; line-height: 24px; }
.carbon-rowhead .v { font-size: 16px; line-height: 24px; font-weight: 500; font-variant-numeric: tabular-nums; }
.carbon-rowhead:hover .n { color: var(--muted); }
.carbon-rowhead:focus { outline: none; }
.carbon-rowhead:focus-visible { outline: 1px dotted var(--muted); outline-offset: -1px; }
.carbon-mini { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; height: 8px; position: relative; }
.carbon-mini::before { content: ''; position: absolute; left: 50%; top: -4px; bottom: -4px; width: 1px; background: var(--muted); }
.carbon-mini i { display: block; height: 8px; }
.carbon-mini .st { justify-self: end; }
.carbon-mini .re { justify-self: start; }
.carbon-detail { display: none; padding: 0 0 24px; }
.carbon-row.on .carbon-detail { display: block; }
.carbon-table table { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 14px; line-height: 20px; font-variant-numeric: tabular-nums; }
.carbon-table th { text-align: right; font-weight: 400; color: var(--muted); padding: 4px 0 8px 16px; border-bottom: 1px solid var(--stone); }
.carbon-table th:first-child, .carbon-table td:first-child { text-align: left; padding-left: 0; }
.carbon-table td { text-align: right; padding: 6px 0 6px 16px; border-bottom: 1px solid var(--stone); }
.carbon-table tfoot td { font-weight: 500; border-bottom: 0; }
.carbon-method { margin-top: 48px; max-width: 60ch; }
@media (max-width: 900px) {
  #carbon { padding: 16px; }
  .carbon-panel { padding: 0 16px 32px; }
  .carbon-head h2 { font-size: 32px; line-height: 36px; }
  .carbon-head .meta { display: none; }
  .carbon-body { grid-template-columns: 1fr; gap: 24px; }
  .carbon-draw { position: relative; top: 0; max-width: 420px; }
  .carbon-draw img { max-height: none; }
  .carbon-net { font-size: 44px; line-height: 48px; }
}
