:root {
  --bg: #f6f4f0;
  --surface: #ffffff;
  --ink: #141414;
  --ink-2: #4a4744;
  --mute: #86817a;
  --line: rgba(20, 20, 20, 0.1);
  --red: #d32a2f;
  --dark: #0f0e0d;

  --pad: clamp(16px, 4vw, 48px);
  --max: 1440px;
  --hdr: 68px;
  --radius: 14px;

  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;

  --ease: cubic-bezier(0.19, 1, 0.22, 1);
}
@media (max-width: 760px) {
  :root { --hdr: 58px; --radius: 10px; }
}

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

html {
  background: var(--bg);
  scroll-padding-top: var(--hdr);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--sans);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--ink); color: var(--bg); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--pad); }

.skip {
  position: fixed; left: 16px; top: -60px; z-index: 300;
  padding: 10px 14px; background: var(--ink); color: #fff; border-radius: 8px; text-decoration: none;
}
.skip:focus { top: 12px; }

.eyebrow {
  margin: 0 0 12px;
  font-size: 12px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--red);
}
.eyebrow--light { color: rgba(255, 255, 255, 0.85); }

.sec-head { margin-bottom: clamp(24px, 4vw, 40px); }
.sec-title {
  margin: 0;
  font: 400 clamp(36px, 5.4vw, 64px)/1.02 var(--serif);
  letter-spacing: -0.01em;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 24px;
  border-radius: 999px;
  font-size: 15px; font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}
.btn:active { transform: scale(0.98); }
.btn svg { width: 16px; height: 16px; fill: currentColor; }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--red); color: #fff; }
.btn--ghost { color: #fff; border: 1px solid rgba(255, 255, 255, 0.55); backdrop-filter: blur(6px); background: rgba(0, 0, 0, 0.12); }
.btn--ghost:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: var(--red); }
.btn--outline { border: 1px solid var(--line); background: var(--surface); }
.btn--outline:hover { border-color: var(--ink); }

.icon-btn {
  display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%;
  color: #fff; background: rgba(255, 255, 255, 0.1);
  transition: background 0.2s;
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.22); }
.icon-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Header ---------- */

.hdr {
  position: fixed; inset: 0 0 auto; z-index: 100;
  height: var(--hdr);
  color: #fff;
  transition: background 0.3s, color 0.3s, box-shadow 0.3s;
}
.hdr::before {
  content: ""; position: absolute; inset: 0 0 -30px; z-index: -1; pointer-events: none;
  background: linear-gradient(rgba(0, 0, 0, 0.45), transparent);
  transition: opacity 0.3s;
}
.hdr__in { height: 100%; display: flex; align-items: center; gap: 24px; }
.hdr__logo { position: relative; display: block; flex: none; }
.logo { height: clamp(22px, 2.3vw, 28px); width: auto; transition: opacity 0.3s; }
.logo--light { filter: drop-shadow(0 1px 8px rgba(0, 0, 0, 0.35)); }
.logo--dark { position: absolute; inset: 0; opacity: 0; }

.hdr__nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.hdr__nav a {
  padding: 8px 14px; border-radius: 999px;
  font-size: 15px; font-weight: 500; text-decoration: none;
  transition: background 0.2s;
}
.hdr__nav a:hover { background: rgba(255, 255, 255, 0.16); }
.hdr__nav a[aria-current="true"] { background: rgba(255, 255, 255, 0.2); }
.hdr__nav .hdr__cta { margin-left: 8px; background: #fff; color: var(--ink); }
.hdr__nav .hdr__cta:hover { background: var(--red); color: #fff; }

.is-scrolled .hdr, .menu-open .hdr {
  background: rgba(246, 244, 240, 0.92);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--line);
}
.is-scrolled .hdr::before, .menu-open .hdr::before { opacity: 0; }
.is-scrolled .logo--dark, .menu-open .logo--dark { opacity: 1; }
.is-scrolled .logo--light, .menu-open .logo--light { opacity: 0; }
.is-scrolled .hdr__nav a:hover { background: rgba(20, 20, 20, 0.06); }
.is-scrolled .hdr__nav a[aria-current="true"] { background: rgba(20, 20, 20, 0.08); }
.is-scrolled .hdr__nav .hdr__cta { background: var(--ink); color: #fff; }
.is-scrolled .hdr__nav .hdr__cta:hover { background: var(--red); }

.hdr__menu {
  display: none; margin-left: auto;
  width: 44px; height: 44px; margin-right: -10px;
  position: relative;
}
.hdr__menu span {
  position: absolute; left: 12px; right: 12px; height: 2px; border-radius: 2px;
  background: currentColor; transition: transform 0.3s var(--ease);
}
.hdr__menu span:first-child { top: 17px; }
.hdr__menu span:last-child { top: 25px; }
.menu-open .hdr__menu span:first-child { transform: translateY(4px) rotate(45deg); }
.menu-open .hdr__menu span:last-child { transform: translateY(-4px) rotate(-45deg); }

.menu {
  position: fixed; inset: var(--hdr) 0 0; z-index: 99;
  background: var(--bg);
  overflow-y: auto;
  opacity: 0; transform: translateY(-8px);
  transition: opacity 0.25s, transform 0.35s var(--ease);
}
.menu.is-open { opacity: 1; transform: none; }
.menu__nav { padding-top: 24px; padding-bottom: 40px; }
.menu__group { padding: 18px 0; border-bottom: 1px solid var(--line); }
.menu__main {
  display: flex; align-items: baseline; justify-content: space-between;
  font: 400 40px/1.1 var(--serif); text-decoration: none;
}
.menu__main small { font: 500 14px var(--sans); color: var(--mute); }
.menu__cats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.menu__cats a {
  padding: 7px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line);
  font-size: 14px; text-decoration: none;
}

@media (max-width: 860px) {
  .hdr__nav { display: none; }
  .hdr__menu { display: block; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex; align-items: flex-end;
  color: #fff; background: var(--dark);
  overflow: hidden;
}
.hero__media, .hero__media img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__media img {
  object-fit: cover; object-position: var(--focus, 50% 50%);
  opacity: 0; transform: scale(1.04);
  transition: opacity 1.2s ease, transform 2.4s var(--ease);
}
.is-ready .hero__media img { opacity: 1; transform: none; }
.hero__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.25) 45%, rgba(0, 0, 0, 0) 70%),
    linear-gradient(to right, rgba(0, 0, 0, 0.35), transparent 60%);
}
.hero__content { position: relative; padding-bottom: clamp(48px, 9vh, 96px); padding-top: calc(var(--hdr) + 40px); }
.hero__title {
  margin: 0;
  font: 400 clamp(52px, 9vw, 128px)/0.95 var(--serif);
  letter-spacing: -0.015em;
}
.hero__title em { display: block; font-style: italic; }
.hero__lead {
  max-width: 34em; margin: 20px 0 0;
  font-size: clamp(16px, 1.5vw, 19px); line-height: 1.55;
  color: rgba(255, 255, 255, 0.88);
}
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

@media (min-width: 900px) {
  .hero--right .hero__content { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
  .hero--right .hero__cta { justify-content: flex-end; }
  .hero--right .hero__shade {
    background:
      linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.2) 45%, rgba(0, 0, 0, 0) 70%),
      linear-gradient(to left, rgba(0, 0, 0, 0.4), transparent 55%);
  }
}

@media (max-width: 520px) {
  .hero__cta .btn { flex: 1 1 100%; }
}

/* ---------- Services ---------- */

.services { padding-top: clamp(64px, 10vw, 128px); padding-bottom: clamp(24px, 4vw, 48px); }
.services__grid {
  display: grid; gap: clamp(12px, 2vw, 24px);
  grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr));
}
.svc {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end;
  min-height: clamp(260px, 32vw, 460px);
  border-radius: var(--radius); overflow: hidden;
  color: #fff; text-decoration: none; background: var(--tone, #2a2724);
  isolation: isolate;
}
.svc img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2;
  transition: transform 1.2s var(--ease);
}
.svc::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.1) 60%);
}
.svc:hover img { transform: scale(1.05); }
.svc__body { padding: clamp(18px, 2.4vw, 28px); }
.svc__title { margin: 0; font: 400 clamp(30px, 3.2vw, 42px)/1 var(--serif); }
.svc__text { margin: 8px 0 0; font-size: 15px; color: rgba(255, 255, 255, 0.85); max-width: 28em; }
.svc__meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; font-size: 13px; font-weight: 500; }
.svc__cats { color: rgba(255, 255, 255, 0.75); }
.svc__go {
  flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: #fff; color: var(--ink); transition: background 0.2s, color 0.2s;
}
.svc__go svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.svc:hover .svc__go { background: var(--red); color: #fff; }
.svc__play {
  position: absolute; top: 18px; right: 18px;
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.2); backdrop-filter: blur(8px);
}
.svc__play svg { width: 16px; height: 16px; fill: #fff; margin-left: 2px; }

@media (max-width: 900px) {
  .services__grid { grid-template-columns: 1fr; }
  .svc { min-height: 0; aspect-ratio: 4 / 3.4; }
}
@media (min-width: 560px) and (max-width: 900px) {
  .services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .svc { aspect-ratio: 4 / 5; }
  .svc:first-child:nth-last-child(odd) { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
}

/* ---------- Portfolio ---------- */

.work { padding-top: clamp(56px, 8vw, 104px); padding-bottom: clamp(64px, 9vw, 120px); }

.bar {
  position: sticky; top: var(--hdr); z-index: 50;
  background: rgba(246, 244, 240, 0.94);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.bar.is-stuck { border-bottom-color: var(--line); }
.bar .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; padding-block: 12px; }

.tabs {
  display: inline-flex; gap: 4px; padding: 4px;
  background: rgba(20, 20, 20, 0.06); border-radius: 999px;
}
.tabs a {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 18px; border-radius: 999px;
  font-size: 15px; font-weight: 500; text-decoration: none; color: var(--ink-2);
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); }
.tabs svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.chips {
  display: flex; gap: 8px;
  overflow-x: auto; scrollbar-width: none;
  margin-inline: calc(var(--pad) * -1); padding-inline: var(--pad);
  scroll-padding-inline: var(--pad);
}
.chips::-webkit-scrollbar { display: none; }
.chips a {
  flex: none; display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 14px; text-decoration: none; white-space: nowrap;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.chips a:hover { border-color: var(--ink); }
.chips a[aria-current="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.chips small { font-size: 12px; color: var(--mute); }
.chips a[aria-current="true"] small { color: rgba(255, 255, 255, 0.7); }

@media (min-width: 761px) {
  .chips { margin-inline: 0; padding-inline: 0; flex-wrap: wrap; }
}
@media (max-width: 760px) {
  .bar .wrap { padding-block: 10px; gap: 10px; }
  .tabs { width: 100%; }
  .tabs a { flex: 1; justify-content: center; padding: 9px 8px; font-size: 14px; }
  .tabs svg { display: none; }
}

.view { padding-top: clamp(24px, 3vw, 40px); transition: opacity 0.25s; }
.view.is-leaving { opacity: 0; }

.group + .group { margin-top: clamp(48px, 6vw, 80px); }
.group__head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  margin-bottom: 16px;
}
.group__title { margin: 0; font: 400 clamp(28px, 3.4vw, 44px)/1.05 var(--serif); }
.group__count { margin: 4px 0 0; font-size: 14px; color: var(--mute); }
.group__more {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  font-size: 15px; font-weight: 500; text-decoration: none;
  padding: 8px 0; border-bottom: 1px solid currentColor;
}
.group__more:hover { color: var(--red); }
.group__foot { display: flex; justify-content: center; margin-top: 24px; }

/* justified photo grid: every photo keeps its proportions, rows fill the width */
.grid {
  --h: 300px;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.grid::after { content: ""; flex-grow: 1e4; }
@media (max-width: 1100px) { .grid { --h: 230px; } }
@media (max-width: 760px) { .grid { --h: 150px; gap: 4px; } }

.tile {
  position: relative;
  flex-grow: var(--ar);
  flex-basis: calc(var(--ar) * var(--h));
  aspect-ratio: var(--ar);
  max-width: 100%;
  border-radius: 6px; overflow: hidden;
  background: var(--tone, #ddd8d0);
  cursor: zoom-in;
}
.tile img {
  width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 0.6s ease, transform 0.8s var(--ease);
}
.tile img.is-loaded { opacity: 1; }
.tile:hover img { transform: scale(1.03); }
.tile__badge {
  position: absolute; left: 8px; top: 8px;
  padding: 2px 8px; border-radius: 999px; background: rgba(0, 0, 0, 0.6); color: #fff;
  font-size: 11px; font-weight: 500; letter-spacing: 0.06em;
}
@media (max-width: 760px) { .tile { border-radius: 3px; } }

/* video cards */
.films {
  display: grid; gap: clamp(20px, 2.4vw, 32px) clamp(12px, 2vw, 24px);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
}
.film { display: block; width: 100%; text-align: left; }
.film__frame {
  position: relative; display: block; aspect-ratio: 16 / 9;
  border-radius: var(--radius); overflow: hidden;
  background: var(--tone, #2a2724);
}
.film__frame img, .film__frame video {
  width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity 0.6s ease, transform 0.9s var(--ease);
}
.film__frame .is-loaded { opacity: 1; }
.film:hover .film__frame img { transform: scale(1.04); }
.film__frame::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.45), transparent 45%);
}
.film__play {
  position: absolute; left: 50%; top: 50%; z-index: 1;
  display: grid; place-items: center; width: 64px; height: 64px; margin: -32px 0 0 -32px;
  border-radius: 50%; background: rgba(255, 255, 255, 0.92); color: var(--ink);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
  transition: transform 0.3s var(--ease), background 0.2s, color 0.2s;
}
.film__play svg { width: 20px; height: 20px; fill: currentColor; margin-left: 3px; }
.film:hover .film__play { transform: scale(1.1); background: var(--red); color: #fff; }
.film__dur {
  position: absolute; right: 12px; bottom: 10px; z-index: 1;
  padding: 2px 8px; border-radius: 6px; background: rgba(0, 0, 0, 0.6); color: #fff;
  font-size: 12px; font-weight: 500; font-variant-numeric: tabular-nums;
}
.film__info { display: block; padding-top: 12px; }
.film__title { display: block; font-size: 18px; font-weight: 500; line-height: 1.3; }
.film__cat { display: block; margin-top: 2px; font-size: 14px; color: var(--mute); }
.film.is-off .film__play { background: rgba(255, 255, 255, 0.5); }

.empty { padding: 72px 0; text-align: center; color: var(--mute); }
.empty p { margin: 0; }
.empty__title { font: 400 36px/1.1 var(--serif); color: var(--ink); margin-bottom: 8px !important; }

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

.contact { background: var(--dark); color: #fff; }
.contact__in { padding-top: clamp(72px, 11vw, 140px); padding-bottom: clamp(72px, 11vw, 140px); text-align: center; }
.contact__title { margin: 0 auto; font: 400 clamp(44px, 8vw, 104px)/0.98 var(--serif); }
.contact__title em { display: block; font-style: italic; color: rgba(255, 255, 255, 0.75); }
.contact__text { max-width: 34em; margin: 20px auto 0; color: rgba(255, 255, 255, 0.75); font-size: 17px; }
.contact__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 36px; }
.contact__links .btn--ghost { backdrop-filter: none; }
.contact__links span { color: rgba(255, 255, 255, 0.6); align-self: center; }

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

.foot { border-top: 1px solid var(--line); }
.foot__in { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; padding-block: 32px; }
.foot__logo { height: 22px; width: auto; }
.foot__legal { margin: 0; font-size: 14px; color: var(--mute); }
.foot__top { margin-left: auto; font-size: 14px; font-weight: 500; text-decoration: none; }
.foot__top:hover { color: var(--red); }
@media (max-width: 560px) { .foot__top { margin-left: 0; } .foot__in { flex-direction: column; align-items: flex-start; } }

/* ---------- Lightbox ---------- */

.lb, .vp { position: fixed; inset: 0; z-index: 200; color: #fff; }
.lb__bg, .vp__bg {
  position: absolute; inset: 0; background: #0b0a09;
  opacity: 0; transition: opacity 0.35s ease;
}
.lb.is-open .lb__bg, .vp.is-open .vp__bg { opacity: 1; }
.lb__stage { position: absolute; inset: 0; touch-action: none; }
.lb__img {
  position: absolute; left: 0; top: 0; transform-origin: 0 0;
  background: var(--tone, #151311); user-select: none; -webkit-user-drag: none;
}
.lb__top, .vp__top {
  position: absolute; inset: 0 0 auto; z-index: 2;
  display: flex; align-items: center; gap: 16px;
  padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left));
  font-size: 14px;
  opacity: 0; transition: opacity 0.3s ease 0.1s;
}
.lb.is-open .lb__top, .vp.is-open .vp__top { opacity: 1; }
.lb__count, .vp__count { font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, 0.7); min-width: 64px; }
.lb__label, .vp__title { flex: 1; text-align: center; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb__close, .vp__close { margin-left: auto; }

.nav-btn {
  position: absolute; top: 50%; z-index: 2; margin-top: -26px;
  width: 52px; height: 52px;
  opacity: 0; transition: opacity 0.3s ease 0.1s, background 0.2s;
}
.nav-btn--prev { left: max(16px, env(safe-area-inset-left)); }
.nav-btn--next { right: max(16px, env(safe-area-inset-right)); }
.lb.is-open .nav-btn, .vp.is-open .nav-btn { opacity: 1; }
.is-single .nav-btn { display: none; }

@media (max-width: 760px) {
  .nav-btn { top: auto; bottom: max(16px, env(safe-area-inset-bottom)); margin-top: 0; }
  .lb__label, .vp__title { font-size: 13px; }
}

/* ---------- Video player ---------- */

.vp__stage {
  position: absolute; inset: 72px clamp(16px, 6vw, 96px) 72px;
  display: grid; place-items: center;
  opacity: 0; transform: scale(0.98);
  transition: opacity 0.35s ease, transform 0.5s var(--ease);
}
.vp.is-open .vp__stage { opacity: 1; transform: none; }
.vp__video { max-width: 100%; max-height: 100%; width: 100%; height: 100%; background: transparent; border-radius: 8px; }
.vp__msg {
  position: absolute; inset: auto 0 50%; text-align: center; margin: 0;
  font-size: 16px; color: rgba(255, 255, 255, 0.85);
}
@media (max-width: 760px) {
  .vp__stage { inset: 64px 0 84px; }
  .vp__video { border-radius: 0; }
}

.noscript { padding: 120px 24px; text-align: center; }

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