/* FORM BUILDS: one stylesheet for the whole site. */

:root {
  --cream: #f9e0c3;
  --ink: #1a1a1a;
  --ink-2: #212121;
  --text: #444;
  --paper: #fcfcfc;
  --white: #fff;
  --font: "Lato", Helvetica, Arial, sans-serif;
  --gutter: clamp(20px, 3vw, 40px);
  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 15px/1.85 var(--font);
  -webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2 { font-weight: 300; margin: 0; }
p { margin: 0 0 1em; text-wrap: pretty; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

.visually-hidden, .skip:not(:focus) {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.skip:focus { position: fixed; z-index: 1000; top: 10px; left: 10px; padding: 10px 16px; background: var(--white); color: var(--ink); }

/* ---------- Loader (first visit per session) ---------- */
.loader { display: none; }
.is-loading .loader { display: block; position: fixed; inset: 0; z-index: 900; pointer-events: none; }
.loader__half { position: absolute; left: 0; right: 0; height: 50.5%; background: #fae0c1; transition: transform .9s var(--ease); }
.loader__half--top { top: 0; }
.loader__half--bottom { bottom: 0; }
.loader__img { position: absolute; top: 50%; left: 50%; width: min(400px, 80vw); height: auto; transform: translate(-50%, -50%); transition: opacity .3s; }
.is-loaded .loader__img { opacity: 0; }
.is-loaded .loader__half--top { transform: translateY(-100%); }
.is-loaded .loader__half--bottom { transform: translateY(100%); }

/* ---------- Header ---------- */
.header {
  position: absolute; z-index: 50; top: 0; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between;
  height: 78px; padding: 0 var(--gutter) 0 34px;
  color: var(--white);
}
.header__logo img { width: 200px; height: auto; }
.header__nav ul { display: flex; align-items: center; margin: 0; padding: 0; list-style: none; }
.header__nav li { display: flex; }
.header__nav a { display: flex; align-items: center; padding: 0 20px; font-size: 14px; line-height: 20px; opacity: .92; transition: opacity .2s; }
.header__nav a:hover, .header__nav a[aria-current] { opacity: 1; }
.header__nav a[aria-current] { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; }
.header__nav .has-rule { border-right: 1px solid rgba(255, 255, 255, .3); }
.icon { display: block; }
.nowrap { white-space: nowrap; }
.header__burger { position: relative; width: 44px; height: 44px; margin-left: 6px; }
.header__burger span { position: absolute; left: 11px; right: 11px; height: 1px; background: currentColor; transition: transform .3s var(--ease); }
.header__burger span:nth-child(1) { top: 15px; }
.header__burger span:nth-child(2) { top: 21px; }
.header__burger span:nth-child(3) { top: 27px; }
.header__burger:hover span:nth-child(2) { transform: scaleX(.6); transform-origin: right; }

/* Company page: the nav crosses both the photo and the cream panel, so it sits on a cream pill with dark text */
@media (min-width: 901px) {
  .header--split .header__nav ul { padding: 9px 4px; border-radius: 999px; background: rgba(249, 224, 195, .82); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
  .header--split .header__nav, .header--split .header__burger { color: var(--text); }
  .header--split .header__nav .has-rule { border-color: rgba(0, 0, 0, .15); }
}

/* ---------- Full-screen video hero (Home, Contact) ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: flex-end; overflow: hidden; background: var(--ink); color: var(--white); }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,0) 25%, rgba(0,0,0,0) 45%, rgba(0,0,0,.55) 100%); }
.hero__text { position: relative; display: flex; align-items: flex-end; gap: 22px; padding: 0 15% 12vh 15%; }
.hero__mark { flex: none; width: 15px; height: auto; margin-bottom: 8px; opacity: .9; }
.hero h1 { font-size: 70px; line-height: 1.14; letter-spacing: -2px; margin-bottom: 18px; }
.hero p { max-width: 640px; font-size: 16px; line-height: 1.75; font-weight: 400; margin: 0; }
.hero--contact h1 { font-size: clamp(36px, 5vw, 70px); word-break: break-word; }
.contact-list { display: flex; flex-wrap: wrap; gap: 6px 26px; font-style: normal; font-size: 16px; line-height: 1.75; }
.contact-list a { display: inline-flex; align-items: center; gap: 8px; border-bottom: 1px solid transparent; }
.contact-list a:hover { border-color: currentColor; }
.contact-list .icon { width: 15px; height: 15px; }

/* ---------- Company: split screen ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; min-height: 100svh; background: var(--cream); }
.split__media { position: relative; background: #000; overflow: hidden; }
.split__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.split__img { display: none; }
.split__panel { display: flex; align-items: center; padding: 120px 8% 80px; color: var(--text); }
.split h1 { font-size: 50px; line-height: 1.3; letter-spacing: -1px; opacity: .85; }
.split hr { width: 50%; margin: 28px 0; border: 0; border-top: 1px solid rgba(0, 0, 0, .12); }
.split p { max-width: 520px; font-size: 16px; }
.kicker { display: inline-block; margin-top: 6px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; font-size: 13px; }
.split__email { display: inline-block; margin-top: 12px; font-size: 30px; font-weight: 300; line-height: 1.4; opacity: .85; border-bottom: 1px solid transparent; transition: border-color .2s; }
.split__email:hover { border-color: currentColor; }

/* ---------- Builds grid ---------- */
.page-work main { background: var(--ink); }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0; padding: 0; list-style: none; }
.grid--three { grid-template-columns: repeat(3, 1fr); }
.card a { position: relative; display: block; overflow: hidden; aspect-ratio: 3 / 2; background: #111; color: var(--white); }
.grid:not(.grid--three) .card a { aspect-ratio: auto; height: clamp(320px, 42vw, 640px); }
.card img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease), filter .6s var(--ease); }
.card a::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 55%, rgba(0,0,0,.55) 100%); pointer-events: none; }
.card a:hover img, .card a:focus-visible img { transform: scale(1.04); filter: grayscale(1); }
.card__caption { position: absolute; z-index: 1; left: 24px; right: 24px; bottom: 20px; display: flex; flex-direction: column; }
.card__title { font-size: 20px; font-weight: 300; line-height: 1.3; }
.card__loc { font-size: 13px; font-weight: 300; opacity: .8; line-height: 1.6; }

/* ---------- Build page ---------- */
.page-build main { background: var(--ink); color: var(--white); }
.build-hero { position: relative; height: 100vh; height: 100svh; min-height: 520px; overflow: hidden; }
.build-hero img { width: 100%; height: 100%; object-fit: cover; }
.build-hero__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.4) 0%, rgba(0,0,0,0) 22%, rgba(0,0,0,0) 50%, rgba(0,0,0,.6) 100%); }
.build-hero__text { position: absolute; left: 10%; right: 10%; bottom: 10vh; }
.build-hero__back { display: inline-block; margin-bottom: 14px; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; opacity: .8; }
.build-hero__back:hover { opacity: 1; }
.build-hero h1 { font-size: 70px; line-height: 1.14; letter-spacing: -2px; }
.build-hero p { font-size: 16px; opacity: .85; margin: 6px 0 0; }

.pager { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid rgba(255,255,255,.1); }
.pager__link { display: flex; flex-direction: column; gap: 4px; padding: 40px 10%; transition: background .3s; }
.pager__link:hover { background: rgba(255,255,255,.04); }
.pager__link--next { text-align: right; border-left: 1px solid rgba(255,255,255,.1); }
.pager__dir { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; opacity: .6; }
.pager__name { font-size: 26px; font-weight: 300; line-height: 1.3; }

.more { padding: 90px 10px 10px; }
.more h2 { padding: 0 calc(10% - 10px) 30px; font-size: 40px; line-height: 1.25; }

/* ---------- Footer (Builds pages) ---------- */
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 30px; padding: 34px var(--gutter); background: var(--ink); color: rgba(255,255,255,.55); font-size: 12px; line-height: 1.6; border-top: 1px solid rgba(255,255,255,.08); }
.footer p { margin: 0; }
.footer a:hover { color: var(--white); }

/* ---------- Menu (burger) ---------- */
.menu { position: fixed; inset: 0; z-index: 200; display: grid; grid-template-columns: 300px minmax(0, 1fr); opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility 0s .45s; }
.menu[hidden] { display: none; }
.menu.is-open { opacity: 1; visibility: visible; transition: opacity .45s var(--ease); }
.menu__side { display: flex; flex-direction: column; gap: 28px; padding: 40px 34px 34px; background: var(--cream); color: var(--text); overflow-y: auto; transform: translateX(-30px); transition: transform .6s var(--ease); }
.menu.is-open .menu__side { transform: none; }
.menu__nav { display: none; }
.menu__details { font-size: 13px; line-height: 1.75; margin-top: 50px; }
.menu__details p { margin-bottom: 1.2em; }
.menu__details a:hover { text-decoration: underline; text-underline-offset: 3px; }
.menu__ig { display: inline-flex; align-items: center; gap: 8px; }
.menu__brand { margin-top: auto; text-align: center; }
.menu__brand img { width: 200px; height: auto; margin: 0 auto 18px; }
.menu__brand p { font-size: 12px; line-height: 1.7; margin: 0; }
.menu__main { position: relative; overflow: hidden; background: var(--ink-2); color: var(--white); }
.menu__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .18; filter: grayscale(1); }
.menu__content { position: relative; height: 100%; overflow-y: auto; padding: 14vh 9% 60px; }
.menu__content h2 { font-size: 40px; line-height: 1.25; margin-bottom: 26px; }
.menu__content p { max-width: 760px; color: rgba(255,255,255,.85); line-height: 1.75; }
.menu__close { position: absolute; top: 22px; right: calc(var(--gutter) - 4px); width: 44px; height: 44px; color: var(--white); }
.menu__close span { position: absolute; top: 21px; left: 10px; right: 10px; height: 1px; background: currentColor; transform: rotate(45deg); }
.menu__close span + span { transform: rotate(-45deg); }

/* Ghost button: two framed layers that rotate apart on hover (from the original site) */
.btn { position: relative; display: inline-block; width: 250px; height: 52px; margin-top: 18px; line-height: 52px; text-align: center; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--white); }
.btn span { position: relative; z-index: 2; }
.btn::before, .btn::after { content: ""; position: absolute; inset: 0; z-index: 1; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.1); transition: transform .5s var(--ease), background .5s; }
.btn:hover::before { transform: rotate(-45deg); background: transparent; }
.btn:hover::after { transform: rotate(45deg); background: transparent; }

/* Client logos marquee */
.logos { margin-top: 12vh; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.logos__track { display: flex; align-items: center; gap: 70px; width: max-content; animation: marquee 40s linear infinite; }
.logos img { height: 46px; width: auto; max-width: 170px; object-fit: contain; opacity: .5; }
@keyframes marquee { to { transform: translateX(calc(-50% - 35px)); } }

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 1s var(--ease) .15s, transform 1s var(--ease) .15s; }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- Tablet ---------- */
@media (max-width: 1100px) {
  .header__nav a { padding: 0 12px; }
  .hero h1, .build-hero h1 { font-size: 56px; }
  .hero__text { padding: 0 8% 12vh; }
}

/* ---------- Phone and small tablet ---------- */
@media (max-width: 900px) {
  .header { height: 64px; padding-left: 20px; padding-right: 10px; }
  .header__logo img { width: 110px; }
  .header__nav { display: none; }

  .hero__text { padding: 0 24px 9vh; gap: 16px; }
  .hero__shade { background: linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,0) 18%, rgba(0,0,0,0) 40%, rgba(0,0,0,.7) 100%); }
  .hero__mark { width: 11px; }
  .hero h1, .build-hero h1 { font-size: 40px; letter-spacing: -1px; }
  .hero p, .contact-list { font-size: 15px; }
  .contact-list { flex-direction: column; gap: 2px; }
  .hero--contact h1 { font-size: 30px; letter-spacing: -.5px; }

  .split { grid-template-columns: 1fr; }
  .split__video { display: none; }
  .split__img { display: block; width: 100%; height: 62vh; object-fit: cover; }
  .split__panel { padding: 60px 24px 70px; text-align: center; justify-content: center; }
  .split h1 { font-size: 34px; }
  .split hr { margin: 24px auto; }
  .split p { margin-left: auto; margin-right: auto; }
  .split__email { font-size: 22px; }

  .grid, .grid--three { grid-template-columns: 1fr; }
  .grid:not(.grid--three) .card a { height: auto; aspect-ratio: 4 / 3; }
  .build-hero__text { left: 24px; right: 24px; }
  .pager__link { padding: 28px 24px; }
  .pager__name { font-size: 19px; }
  .more { padding-top: 60px; }
  .more h2 { padding: 0 14px 20px; font-size: 30px; }

  .menu { display: block; overflow-y: auto; }
  .menu__side { overflow: visible; }
  .menu__side { transform: none; padding: 90px 24px 34px; gap: 22px; }
  .menu__main { overflow: visible; }
  .menu__content { height: auto; padding: 60px 24px 50px; }
  .menu__nav { display: flex; flex-direction: column; gap: 2px; }
  .menu__nav a { font-size: 32px; font-weight: 300; line-height: 1.35; }
  .menu__details { margin-top: 0; }
  .menu__brand { display: none; }
  .menu__close { color: var(--text); top: 10px; right: 10px; }
  .menu__content h2 { font-size: 28px; }
  .logos { margin-top: 50px; }
  .logos img { height: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: 0s !important; transition-delay: 0s !important; }
  .js .reveal { opacity: 1; transform: none; }
}
