/* Editorial portfolio - light, image-led, restrained. */
:root {
  --paper: #fbfaf7;
  --paper-2: #f3f1ea;
  --ink: #1a1916;
  --ink-soft: #4a4843;
  --muted: #8a867c;
  --faint: #b3afa2;
  --line: rgba(26, 25, 22, 0.12);
  --line-soft: rgba(26, 25, 22, 0.07);
  --maxw: 1180px;
  --gutter: 40px;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 17px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
::selection { background: #e9e4d6; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }
.lede, .page-head h1, .case-title, .post-title { text-wrap: balance; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

.site-head { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line-soft); }
.site-head .wrap { display: flex; align-items: baseline; justify-content: space-between; padding-top: 22px; padding-bottom: 22px; }
.brand { font-weight: 500; font-size: 16px; letter-spacing: -0.01em; }
.site-head nav { display: flex; gap: 30px; }
.site-head nav a { font-size: 14px; color: var(--muted); position: relative; padding-bottom: 2px; transition: color 0.2s var(--ease); }
.site-head nav a:hover, .site-head nav a.on { color: var(--ink); }
.site-head nav a.on::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--ink); }

.lede-wrap { padding: 120px 0 90px; border-bottom: 1px solid var(--line-soft); }
.lede-eyebrow { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 28px; }
.lede { font-family: var(--serif); font-weight: 300; font-size: clamp(2.4rem, 5.2vw, 4.3rem); line-height: 1.08; letter-spacing: -0.015em; margin: 0; max-width: 16ch; }
.lede em { font-style: italic; }
.lede-sub { font-size: 1.15rem; color: var(--ink-soft); max-width: 52ch; margin: 34px 0 0; line-height: 1.6; }

.section { padding: 80px 0; }
.section + .section { border-top: 1px solid var(--line-soft); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 46px; }
.section-head h2 { font-weight: 500; font-size: 13px; letter-spacing: 0.08em; color: var(--muted); margin: 0; text-transform: uppercase; }
.section-link { font-size: 14px; color: var(--muted); transition: color 0.2s var(--ease); }
.section-link:hover { color: var(--ink); }

.work-index { border-top: 1px solid var(--line); }
.work-row { display: grid; grid-template-columns: 56px 1fr auto; align-items: center; gap: 24px; padding: 26px 8px; border-bottom: 1px solid var(--line); transition: padding-left 0.3s var(--ease), background 0.3s var(--ease); }
.work-row:hover { padding-left: 20px; background: var(--paper-2); }
.work-num { font-size: 14px; color: var(--faint); font-variant-numeric: tabular-nums; }
.work-id { display: flex; flex-direction: column; gap: 4px; }
.work-name { font-family: var(--serif); font-weight: 400; font-size: 1.9rem; line-height: 1.05; letter-spacing: -0.01em; }
.work-tag { font-size: 14px; color: var(--muted); }
.work-meta { display: flex; align-items: center; gap: 22px; }
.work-status { font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.work-arrow { color: var(--faint); transition: transform 0.3s var(--ease), color 0.2s; font-size: 18px; }
.work-row:hover .work-arrow { transform: translateX(6px); color: var(--ink); }

.gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; }
.tile { display: block; position: relative; overflow: hidden; }
.tile-img { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--paper-2); }
.tile-img img, .tile-img svg { width: 100%; height: 100%; object-fit: cover; transition: transform 0.7s var(--ease); }
.tile:hover .tile-img img, .tile:hover .tile-img svg { transform: scale(1.03); }
.tile-cap { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 16px 4px 28px; }
.tile-cap .t-name { font-family: var(--serif); font-size: 1.35rem; font-weight: 400; letter-spacing: -0.01em; }
.tile-cap .t-side { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; text-align: right; }
.tile-cap .t-tag { font-size: 13.5px; color: var(--muted); text-align: right; }
.tile-cap .t-status { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--faint); }
.gallery .tile.feature { grid-column: 1 / -1; }
.gallery .tile.feature .tile-img { aspect-ratio: 21 / 9; }
.gallery .tile.feature .t-name { font-size: 1.7rem; }

.page-head { padding: 96px 0 40px; border-bottom: 1px solid var(--line-soft); }
.page-head .lede-eyebrow { margin-bottom: 18px; }
.page-head h1 { font-family: var(--serif); font-weight: 300; font-size: clamp(2.2rem, 5vw, 3.6rem); letter-spacing: -0.015em; line-height: 1.05; margin: 0; max-width: 18ch; }
.page-head .page-sub { font-size: 1.1rem; color: var(--ink-soft); max-width: 54ch; margin: 24px 0 0; }

.back { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); padding: 40px 0 0; transition: color 0.2s var(--ease); }
.back:hover { color: var(--ink); }
.case { padding-bottom: 40px; }
.case-hero { margin: 40px 0 0; }
.case-hero .tile-img { aspect-ratio: 16 / 9; border: 1px solid var(--line-soft); }
.case-head { margin: 56px 0 0; }
.case-title { font-family: var(--serif); font-weight: 300; font-size: clamp(2.4rem, 6vw, 4.2rem); letter-spacing: -0.02em; line-height: 1.02; margin: 0; }
.case-tagline { font-size: 1.2rem; color: var(--ink-soft); margin: 18px 0 0; }
.case-meta { display: flex; flex-wrap: wrap; gap: 22px 48px; margin: 40px 0 0; padding: 22px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.case-meta .m { display: flex; flex-direction: column; gap: 4px; }
.case-meta .m-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--faint); }
.case-meta .m-val { font-size: 15px; color: var(--ink); }
.case-body { max-width: 680px; margin: 56px 0 0; }
.case-lede { font-family: var(--serif); font-weight: 300; font-size: 1.55rem; line-height: 1.45; color: var(--ink); margin: 0 0 40px; }
.case-section { margin: 0 0 36px; }
.case-section h3 { font-weight: 500; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.case-section p { font-size: 1.06rem; line-height: 1.72; color: var(--ink-soft); margin: 0; }

.loglist { border-top: 1px solid var(--line); }
.logrow { display: grid; grid-template-columns: 130px 1fr auto; gap: 26px; align-items: baseline; padding: 24px 8px; border-bottom: 1px solid var(--line); transition: padding-left 0.3s var(--ease), background 0.3s var(--ease); }
.logrow:hover { padding-left: 16px; background: var(--paper-2); }
.row-date { font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.row-main { display: flex; flex-direction: column; gap: 8px; }
.row-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.row-proj { font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--faint); }
.row-title { font-family: var(--serif); font-weight: 400; font-size: 1.3rem; letter-spacing: -0.01em; }
.row-summary { font-size: 0.98rem; color: var(--ink-soft); max-width: 60ch; }
.row-arrow { color: var(--faint); transition: transform 0.3s var(--ease), color 0.2s; }
.logrow:hover .row-arrow { transform: translateX(5px); color: var(--ink); }
.tag { font-size: 11px; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-soft); border: 1px solid var(--line); border-radius: 2px; padding: 2px 8px; white-space: nowrap; }

.prose { max-width: 680px; margin: 0; font-size: 1.08rem; line-height: 1.75; color: var(--ink-soft); }
.prose h2 { font-family: var(--serif); font-weight: 400; color: var(--ink); font-size: 1.7rem; margin: 44px 0 14px; letter-spacing: -0.01em; }
.prose h3 { font-weight: 500; color: var(--ink); font-size: 1.1rem; margin: 32px 0 10px; }
.prose p { margin: 0 0 20px; }
.prose ul, .prose ol { padding-left: 22px; margin: 0 0 20px; }
.prose li { margin: 7px 0; }
.prose a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); }
.prose a:hover { text-decoration-color: var(--ink); }
.prose code { font-family: ui-monospace, monospace; font-size: 0.9em; background: var(--paper-2); padding: 2px 6px; border-radius: 3px; }
.prose pre { background: var(--paper-2); border: 1px solid var(--line-soft); border-radius: 6px; padding: 18px; overflow-x: auto; }
.prose pre code { background: none; padding: 0; }
.prose blockquote { border-left: 2px solid var(--ink); margin: 0 0 20px; padding-left: 20px; color: var(--muted); font-family: var(--serif); font-style: italic; }

.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; max-width: 680px; margin: 40px 0 0; }
.post-date { font-size: 14px; color: var(--faint); }
.post-title { font-family: var(--serif); font-weight: 300; font-size: clamp(2rem, 4.6vw, 3.1rem); letter-spacing: -0.015em; line-height: 1.08; max-width: 680px; margin: 18px 0 36px; }
a.post-proj, span.post-proj { font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
a.post-proj:hover { color: var(--ink); }
.empty { color: var(--faint); padding: 30px 0; }

.about-body { max-width: 620px; }
.about-body p { font-size: 1.18rem; line-height: 1.7; color: var(--ink-soft); margin: 0 0 22px; }
.about-body .serif-open { font-family: var(--serif); font-weight: 300; font-size: 1.5rem; line-height: 1.5; color: var(--ink); }
.about-links a { font-size: 15px; color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line); }
.about-links a:hover { text-decoration-color: var(--ink); }

.site-foot { border-top: 1px solid var(--line); margin-top: 40px; }
.site-foot .wrap { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; padding-top: 40px; padding-bottom: 56px; flex-wrap: wrap; }
.foot-brand { font-family: var(--serif); font-size: 1.4rem; font-weight: 400; }
.foot-links { display: flex; gap: 22px; }
.foot-links a { font-size: 14px; color: var(--muted); transition: color 0.2s var(--ease); }
.foot-links a:hover { color: var(--ink); }
.foot-meta { font-size: 13px; color: var(--faint); margin-left: auto; }

@media (max-width: 820px) {
  :root { --gutter: 22px; }
  .lede-wrap { padding: 80px 0 60px; }
  .gallery { grid-template-columns: 1fr; }
  .gallery .tile.feature .tile-img { aspect-ratio: 16 / 10; }
  .work-row { grid-template-columns: 32px 1fr auto; gap: 14px; }
  .work-name { font-size: 1.5rem; }
  .work-status { display: none; }
  .tile-cap { flex-direction: column; align-items: flex-start; gap: 4px; padding-bottom: 34px; }
  .tile-cap .t-side { align-items: flex-start; text-align: left; }
  .tile-cap .t-tag { text-align: left; }
  .case-meta { flex-wrap: wrap; gap: 22px; }
  .logrow { grid-template-columns: 1fr; gap: 8px; }
  .row-date { order: -1; }
  .row-arrow { display: none; }
  .site-head nav { gap: 18px; }
  .foot-meta { margin-left: 0; width: 100%; }
}

/* ---------- case study: metrics, highlights, status, coming-soon ---------- */
.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 24px 36px; margin: 36px 0 0; }
.metric { border-top: 1px solid var(--ink); padding: 14px 0 0; }
.metric-val { display: block; font-family: var(--serif); font-weight: 400; font-size: 1.7rem; letter-spacing: -0.01em; color: var(--ink); line-height: 1.1; font-variant-numeric: tabular-nums; }
.metric-label { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-top: 8px; }

.highlights { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 32px; }
.hl { border-top: 1px solid var(--line); padding: 14px 0 0; display: flex; flex-direction: column; gap: 6px; }
.hl-title { font-family: var(--serif); font-size: 1.15rem; color: var(--ink); }
.hl-text { font-size: 0.96rem; color: var(--ink-soft); line-height: 1.55; }

/* status accents (work index + tiles) */
.work-status.st-coming-soon, .t-status.st-coming-soon { color: var(--ink); }
.work-status.st-paused, .t-status.st-paused { color: var(--faint); }

/* coming-soon case teaser */
.soon-badge {
  display: inline-block; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); border-radius: 20px; padding: 4px 12px; margin: 16px 0 4px;
}
.case.soon .case-head { margin-top: 40px; }
.soon-note { font-size: 1rem; color: var(--muted); margin: 28px 0 0; }
.soon-note a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.tile.soon .tile-img { background: var(--paper-2); }

@media (max-width: 820px) {
  .highlights { grid-template-columns: 1fr; gap: 20px; }
  .metrics { grid-template-columns: 1fr 1fr; gap: 20px 24px; }
}

/* hero walkthrough video */
.hero-video { width: 100%; height: 100%; object-fit: cover; display: block; background: #0c0e12; }
.case-hero .tile-img:has(.hero-video) { background: #0c0e12; }

/* ---------- home: featured triptych (selected work) ---------- */
.feat3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.feat3 .ftile { display: block; position: relative; }
.feat3 .ftile-img { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--paper-2); border: 1px solid var(--line-soft); }
.feat3 .ftile-img img, .feat3 .ftile-img svg { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease); }
.feat3 .ftile:hover .ftile-img img, .feat3 .ftile:hover .ftile-img svg { transform: scale(1.045); }
.feat3 .ftile-num { font-size: 12px; letter-spacing: 0.12em; color: var(--faint); font-variant-numeric: tabular-nums; margin-right: 10px; vertical-align: 3px; }
.feat3 .ftile-cap { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 16px 2px 0; }
.feat3 .ft-name { font-family: var(--serif); font-size: 1.3rem; font-weight: 400; letter-spacing: -0.01em; min-width: 0; overflow-wrap: anywhere; }
.feat3 .ft-tag { font-size: 12.5px; color: var(--muted); text-align: right; max-width: 22ch; min-width: 0; }

/* ---------- about: minimal ---------- */
.about-section .about-body { margin-bottom: 34px; }
.about-links { display: flex; flex-wrap: wrap; gap: 26px; }

@media (max-width: 820px) {
  .feat3 { grid-template-columns: 1fr; gap: 6px; }
  .feat3 .ftile-img { aspect-ratio: 16 / 10; }
  .feat3 .ftile-cap { padding-bottom: 18px; }
}

/* ---------- short project description (blurb) on the project page ---------- */
.case-blurb { font-size: 1.06rem; line-height: 1.6; color: var(--ink-soft); margin: 0 0 28px; max-width: 60ch; }

/* ---------- listing hover-to-play video (poster still until hover) ---------- */
.hover-video { width: 100%; height: 100%; object-fit: cover; display: block; background: #0c0e12; }
.tile-img:has(.hover-video), .feat3 .ftile-img:has(.hover-video) { background: #0c0e12; }

/* ---------- post-video screenshot gallery (lead + thumbs) + lightbox ---------- */
.hero-stage { position: relative; }
.hero-media.is-done { display: none; }
.hero-grid { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: repeat(2, 1fr); gap: 6px; aspect-ratio: 16 / 9; }
.hero-grid[hidden] { display: none; }
.hero-grid .shot { position: relative; overflow: hidden; border: 1px solid var(--line-soft); background: var(--paper-2); cursor: zoom-in; }
.hero-grid .shot img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease); }
.hero-grid .shot:hover img { transform: scale(1.04); }
.hero-grid .shot-lead { grid-row: 1 / 3; }
.hero-grid.revealing { animation: heroFade 0.5s var(--ease); }
@keyframes heroFade { from { opacity: 0; } to { opacity: 1; } }

.lb-overlay { position: fixed; inset: 0; z-index: 200; background: rgba(12, 14, 18, 0.92); display: flex; align-items: center; justify-content: center; }
.lb-overlay[hidden] { display: none; }
.lb-img { max-width: 92vw; max-height: 86vh; object-fit: contain; box-shadow: 0 12px 48px rgba(0, 0, 0, 0.5); }
.lb-btn { position: fixed; background: none; border: 0; color: #f3f1ea; cursor: pointer; line-height: 1; opacity: 0.85; transition: opacity 0.2s var(--ease); font-family: var(--sans); }
.lb-btn:hover { opacity: 1; }
.lb-close { top: 18px; right: 24px; font-size: 34px; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); font-size: 56px; padding: 0 10px; }
.lb-prev { left: 18px; }
.lb-next { right: 18px; }
@media (max-width: 820px) { .hero-grid { aspect-ratio: 4 / 3; } .lb-prev, .lb-next { font-size: 40px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

