/* Inter, self-hosted (fonts/, SIL Open Font License). One variable file covers every weight. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("fonts/inter-var-latin.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("fonts/inter-var-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }

:root {
  --bg: #f4f5f3;
  --ink: #111;
  --muted: #6b6e6a;
  --line: #e2e4e0;
  --accent: #ed5829;
  --radius: 14px;
  --gap: 14px;
  --pad: clamp(16px, 3vw, 32px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; background: var(--bg); }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  /* Like the original site: content stops growing at 1600px and centers on very wide screens */
  max-width: 1600px;
  margin: 0 auto;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: clamp(16px, 1.6vw, 24px) var(--pad);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s;
}
/* Hairline appears once the page scrolls under the header; clean at the top */
.site-header.scrolled { border-bottom-color: var(--line); }
/* Header type scales with the screen: ~34px logo on phones up to 48px on wide desktops */
.logo { font-weight: 800; font-size: clamp(34px, 1.8vw + 24px, 48px); letter-spacing: 0.02em; word-spacing: 0.05em; line-height: 1; white-space: nowrap; }
/* Hidden visually but still read by search engines and screen readers */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.site-header nav { display: flex; align-items: center; gap: clamp(10px, 1.1vw, 18px); font-weight: 600; font-size: clamp(14px, .35vw + 12.5px, 17px); letter-spacing: .1em; text-transform: uppercase; }
/* "/" between Work and Contact, like the one in the E / P logo. Its own flex item, so it keeps one look on every page */
.site-header nav::after { content: "/"; content: "/" / ""; order: 1; color: var(--accent); font-weight: 600; letter-spacing: 0; }
.site-header nav a:first-child { order: 0; }
.site-header nav a:last-child { order: 2; }
.site-header nav a { opacity: 0.55; transition: opacity .2s; }
.site-header nav a:hover, .site-header nav a[aria-current] { opacity: 1; }

/* ---------- intro + filters ---------- */
.intro {
  display: flex; flex-direction: column; align-items: flex-end; gap: 16px;
  padding: 18px var(--pad) 20px;
}
.intro h1 { font-size: clamp(34px, 6vw, 64px); font-weight: 700; letter-spacing: -0.015em; line-height: 1; text-transform: uppercase; }
.intro p { color: var(--muted); margin-top: 8px; }
/* Homepage: "Director + Editor" on the left, filters on the right, one line */
/* Fixed positions per size (no wrapping/sliding): one row on tablet/desktop, stacked on phones */
.home-intro { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px 16px; padding-top: 18px; }
.home-intro .filters { flex-wrap: nowrap; }
@media (max-width: 699px) {
  .home-intro { grid-template-columns: 1fr; justify-items: center; text-align: center; padding-top: 24px; }
  .home-intro .filters {
    justify-content: safe center; overflow-x: auto; scrollbar-width: none; max-width: 100vw;
    margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad); /* swipe sideways if a tiny phone can't fit all four */
  }
  .home-intro .filters::-webkit-scrollbar { display: none; }
  .home-intro .filters button { flex: none; }
}
.role { font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.role span { color: var(--accent); font-weight: 700; margin: 0 2px; }
@media (max-width: 699px) { .role { display: none; } } /* tablet and desktop only: phones stack the intro, and it shouldn't sit above the filters */
.filters { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.filters button {
  border: 1px solid var(--line); background: transparent;
  padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 500;
  transition: background .2s, color .2s, border-color .2s;
}
.filters button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ---------- justified grid: every row the same height, edges flush ---------- */
.grid { display: flex; align-items: stretch; gap: var(--gap); padding: 0 var(--pad) var(--pad); }
.col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--gap); }
.card { display: block; min-width: 0; }
/* Spare height is shared by every clip in a column (each crops a touch) so columns end level */
.col .card { flex: 1 1 auto; display: flex; flex-direction: column; }
.col .card .media { flex: 1 1 auto; }
/* Music Videos filter: 3 equal widescreen tiles per row (2 on phones) */
.grid.uniform { display: grid; grid-template-columns: repeat(3, 1fr); align-items: start; }
.grid.uniform .media { aspect-ratio: 16 / 9; }
@media (max-width: 699px) { .grid.uniform { grid-template-columns: repeat(2, 1fr); } }
.card[hidden] { display: none; }
.grid.big {
  columns: auto; display: grid; align-items: start;
  grid-template-columns: repeat(var(--n, 1), 1fr); gap: var(--gap);
  max-width: calc(1100px + 2 * var(--pad)); margin: 0 auto;
}
.grid.big .card { margin: 0; }
/* A filter with a single project (Brand): a moderate centered tile that fits on screen, not full width */
.grid.big[data-count="1"] { grid-template-columns: minmax(0, min(720px, calc((100svh - 260px) * 4 / 3))); justify-content: center; }
/* Social: vertical, phone-shaped tiles */
.grid.big[data-filter="social"] { grid-template-columns: repeat(var(--n, 1), minmax(0, 380px)); justify-content: center; }
.grid.big[data-filter="social"] .media { aspect-ratio: 9 / 16; }
/* Three Social pieces: one row of three on wider screens instead of two plus one */
@media (min-width: 900px) { .grid.big[data-filter="social"][data-count="3"] { grid-template-columns: repeat(3, minmax(0, 340px)); } }
.grid.big .meta .artist { font-size: 16px; }
.grid.big .meta .title { font-size: 15px; }
.media {
  position: relative; overflow: hidden;
  border-radius: var(--radius);
  aspect-ratio: var(--r, 16/9);
  background: #dfe1dd;
}
.media video, .media img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: var(--focus, 50% 50%); display: block;
  transition: transform .6s cubic-bezier(.2,.7,.2,1);
}
.pill {
  position: absolute; top: 10px; left: 10px; z-index: 2;
  /* frosted glass: the clip shows through, text stays readable */
  background: rgba(255,255,255,.55); color: #111;
  backdrop-filter: blur(8px) saturate(140%); -webkit-backdrop-filter: blur(8px) saturate(140%);
  font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 999px;
}
.pill.award::before { content: "★ "; color: var(--accent); }
.pill { white-space: nowrap; max-width: calc(100% - 20px); overflow: hidden; } /* never wraps onto two lines */
.pill .short { display: none; }
.pill.tight .long { display: none; } .pill.tight .short { display: inline; } /* full badge doesn't fit this tile */
@media (max-width: 699px) {
  /* phones: shorter, smaller "★ Award Nominee" */
  .pill .long { display: none; } .pill .short { display: inline; }
  .pill { font-size: 9px; padding: 4px 8px; top: 8px; left: 8px; }
}
.meta { padding: 8px 2px 4px; }
.meta .artist { display: block; font-size: 13px; font-weight: 600; }
body:not(.theater) .meta .artist { text-transform: uppercase; letter-spacing: .06em; font-size: 12px; } /* homepage: artist/brand in caps */
.meta .title { display: block; font-size: 13px; color: var(--muted); }

/* Desktop: gentle zoom on hover, no overlay */
@media (hover: hover) {
  .card:hover .media video, .card:hover .media img { transform: scale(1.03); }
}
@media (max-width: 699px) {
  .grid { --gap: 10px; }
}

/* ---------- footer ---------- */
.site-footer {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  /* clear break from the content: space, then a hairline lined up with the grid edges */
  margin: clamp(32px, 5vw, 56px) var(--pad) 0;
  padding: 22px 0 40px; border-top: 1px solid var(--line);
  color: var(--muted); font-size: 11px; letter-spacing: .02em;
}
.site-footer a:hover { color: var(--ink); }

/* ---------- project page: theater mode ---------- */
.player-wrap { padding: 8px var(--pad) 0; }
.player {
  position: relative; max-width: min(1400px, calc(78vh * var(--vr, 16 / 9))); margin: 0 auto;
  aspect-ratio: var(--vr, 16 / 9); border-radius: var(--radius); overflow: hidden; background: #000;
  box-shadow: 0 20px 50px rgba(0,0,0,.18);
}
.player video, .player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
/* Projects with several cuts (e.g. Fletchy): players side by side, each as tall as a single player would be */
.player-wrap.multi { display: flex; justify-content: center; gap: var(--gap); }
.player-wrap.multi .player { margin: 0; width: calc(78vh * var(--vr)); max-width: calc((100% - var(--gap)) / 2); }
/* Campaign layout (e.g. CRWNZ): one full-size player, then smaller spots side by side underneath */
.player-wrap.hero { display: flex; flex-direction: column; align-items: center; gap: var(--gap); }
.player-wrap.hero > .player, .player-row { width: 100%; max-width: min(1400px, calc(78vh * var(--vr))); margin: 0; }
.player-row { display: flex; gap: var(--gap); }
.player-row .spot { flex: 1; min-width: 0; margin: 0; }
.player-row .player { width: 100%; max-width: none; margin: 0; box-shadow: 0 12px 30px rgba(0,0,0,.14); }
.spot figcaption { padding: 8px 2px 0; font-size: 13px; color: var(--muted); }
.details {
  max-width: 1400px; margin: 0 auto;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px;
  padding: 36px var(--pad) 20px;
}
.details h1 { font-size: clamp(40px, 7vw, 88px); font-weight: 700; letter-spacing: -0.04em; line-height: .95; }
.details .by { font-size: 18px; color: var(--muted); margin-top: 10px; }
.awards { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.awards span {
  border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 12px; font-size: 12px; font-weight: 500;
}
.awards span::before { content: "★ "; color: var(--accent); }
/* Credits: white card, small caps labels over values, hairline dividers */
.credits {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; align-content: start;
  background: #edece8; /* soft warm gray, a touch darker than the page background */
  border-radius: var(--radius); padding: 22px 26px 8px;
}
.credits h2 {
  grid-column: 1 / -1; margin-bottom: 6px;
  font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent);
}
.credits div { padding: 14px 0 16px; border-top: 1px solid #dddbd5; }
.credits dt { font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.credits dd { margin-top: 4px; font-size: 16px; font-weight: 500; line-height: 1.35; }
/* phones keep the same two-column layout as desktop, just a little tighter */
@media (max-width: 480px) {
  .credits { gap: 0 18px; padding: 18px 18px 6px; }
  .credits dd { font-size: 14px; }
}
.pager {
  max-width: 1400px; margin: 0 auto;
  display: flex; justify-content: space-between; gap: 16px;
  padding: 20px var(--pad); border-top: 1px solid var(--line);
}
.pager a { display: flex; flex-direction: column; gap: 2px; max-width: 45%; }
.pager a:last-child { text-align: right; }
.pager small { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.pager span { font-weight: 600; }
.pager a:hover span { color: var(--accent); }
.more-head { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: 28px var(--pad) 14px; max-width: 1400px; margin: 0 auto; }
.theater .grid {
  max-width: calc(1400px + 2 * var(--pad)); margin: 0 auto;
  columns: auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap);
}
.theater .card { margin: 0; }
.theater .media { aspect-ratio: 4 / 5; }
@media (max-width: 699px) { .theater .grid { grid-template-columns: repeat(2, 1fr); } }

/* Project gallery: rows of still + looping clip */
.gallery { max-width: 1400px; margin: 0 auto; padding: 8px var(--pad) 28px; display: grid; gap: var(--gap); }
.g-row { display: flex; gap: var(--gap); }
.g-label { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-top: 10px; }
.g-label:first-child { margin-top: 0; }
/* width ∝ shape, so tiles in a row share one height */
.g-tile { position: relative; flex: var(--r, 1.333) 1 0; aspect-ratio: var(--r, 4 / 3); border-radius: var(--radius); overflow: hidden; background: #dfe1dd; }
.g-row > .g-tile:only-child { flex: 0 1 calc(78vh * var(--r, 1.333)); margin: 0 auto; } /* lone tile: never taller than the screen */
.g-tile.blank { background: transparent; border: 1.5px dashed var(--line); display: grid; place-items: center; }
.g-tile.blank span { font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.g-tile img, .g-tile video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--focus, 50% 50%); }
@media (max-width: 699px) {
  /* phones: rows stay side by side (2 per row), just with a tighter gap */
  .g-row { gap: 8px; }
  .gallery { gap: 8px; }
  .g-row > .g-tile:only-child { flex-basis: calc(70vh * var(--r, 1.333)); }
  /* very wide tiles (e.g. scope 2.4:1) switch to 4:3 on phones, two across like every other gallery */
  .g-row.wide > .g-tile { flex: 1 1 0; aspect-ratio: 4 / 3; }
}

.details.solo { grid-template-columns: 1fr; }
.details .note { color: var(--muted); margin-top: 16px; max-width: 52ch; }
/* No note or awards on this project: drop their empty spacing so the credits sit closer */
.details .note:empty, .details .awards:empty { display: none; }

/* ---------- about page ---------- */
.about { max-width: 1300px; margin: 0 auto; }
.bts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); padding: 8px var(--pad) 0; }
.bts-panel { position: relative; aspect-ratio: 5 / 4; border-radius: var(--radius); overflow: hidden; background: #dfe1dd; }
.bts-panel img, .bts-panel video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 699px) { .bts { gap: 8px; } } /* phones: still side by side, tighter gap */
.about-hero { padding: clamp(40px, 7vw, 80px) var(--pad) 48px; }
.about-hero h1 { font-size: clamp(44px, 8vw, 104px); font-weight: 700; letter-spacing: -0.045em; line-height: .95; max-width: 12ch; }
.about-hero p { font-size: clamp(17px, 2vw, 21px); color: var(--muted); margin-top: 24px; max-width: 46ch; }
.contact-row { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 32px; }
.email-btn {
  background: var(--ink); color: var(--bg);
  padding: 14px 22px; border-radius: 999px; font-weight: 600;
  transition: background .2s;
}
.email-btn:hover { background: var(--accent); }
.links { display: flex; gap: 18px; font-weight: 500; }
.links a:hover { color: var(--accent); }
/* Phones: smaller email button so email, Instagram and TikTok share one line like desktop */
@media (max-width: 699px) {
  .contact-row { gap: 14px; margin-top: 24px; }
  .email-btn { padding: 10px 16px; font-size: 14px; }
  .links { gap: 14px; font-size: 14px; }
}
.about-awards .more-head { padding-left: var(--pad); }
/* Awards: two columns at every size, year as a small label above each award */
.timeline {
  list-style: none; padding: 0 var(--pad) 48px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(16px, 4vw, 48px);
}
.timeline li { padding: 16px 0 18px; border-top: 1px solid var(--line); }
.timeline .year { display: block; font-size: 12px; font-weight: 600; letter-spacing: .08em; color: var(--accent); font-variant-numeric: tabular-nums; margin-bottom: 4px; }
.timeline strong { display: block; font-weight: 600; line-height: 1.3; }
.timeline small { display: block; color: var(--muted); font-size: 14px; margin-top: 3px; line-height: 1.35; }
@media (max-width: 699px) {
  .timeline li { padding: 12px 0 14px; }
  .timeline strong { font-size: 13px; }
  .timeline small { font-size: 12px; }
}

@media (max-width: 800px) {
  .details { grid-template-columns: 1fr; gap: 24px; }
  .player-wrap { padding: 0; }
  .player { border-radius: 0; }
}
/* Several cuts on a phone: stacked, keeping the rounded corners and side margins */
@media (max-width: 699px) {
  .player-wrap.multi { flex-direction: column; align-items: center; padding: 0 var(--pad); }
  .player-wrap.multi .player { width: min(100%, calc(78vh * var(--vr))); max-width: 100%; border-radius: var(--radius); }
}
@media (max-width: 699px) {
  .player-row { flex-direction: column; padding: 0 var(--pad); }
  .player-row .player { border-radius: var(--radius); }
}
@media (min-width: 700px) and (max-width: 800px) {
  .player-row { padding: 0 var(--pad); }
  .player-row .player { border-radius: var(--radius); }
  .player-wrap.multi { padding: 8px var(--pad) 0; }
  .player-wrap.multi .player { border-radius: var(--radius); }
}

/* ---------- back to top ---------- */
.to-top {
  position: fixed; right: max(var(--pad), calc((100vw - 1600px) / 2 + var(--pad))); bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 20;
  border: 0; border-radius: 999px; padding: 10px 16px;
  background: var(--ink); color: var(--bg);
  font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  box-shadow: 0 6px 20px rgba(0,0,0,.18);
  opacity: 0; transform: translateY(10px); pointer-events: none;
  transition: opacity .25s, transform .25s;
}
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--accent); }

@media (max-width: 400px) {
  .home-intro .filters button { padding: 6px 11px; font-size: 12px; } /* all four fit on small phones */
}

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