/* Alphabet Mafia Consultancy
   Nightlife system: black room, blood-red light, Futura-style caps (Jost), Archivo body.
   Shape rule: buttons are full pills, tiles and images are 18px, inputs are 12px. */

@font-face {
  font-family: "Jost";
  src: url("../assets/fonts/jost-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Archivo";
  src: url("../assets/fonts/archivo-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  --black: #050404;
  --tile: #121010;
  --tile-2: #1a1717;
  --line: #2a2525;
  --white: #f6f2ee;
  --dim: #b9b0aa;
  --faint: #8c837d;

  --blood-deep: #3d0308;
  --blood: #7a0812;      /* fills */
  --blood-2: #a10e1a;    /* gradient end; white text on it is 6.8:1 */
  --blood-lit: #d01b28;  /* large type on black only */
  --blood-text: #ff4b57; /* small red text on black */
  --grad: linear-gradient(100deg, #4a050c 0%, #8a0a15 48%, #b8121f 100%);

  --head: "Jost", "Futura", "Avenir Next", system-ui, sans-serif;
  --sans: "Archivo", system-ui, sans-serif;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  --gutter: clamp(16px, 3.4vw, 44px);
  --max: 1320px;
  --nav-h: 76px;
  --section: clamp(80px, 10vw, 150px);
  --r: 18px;
  --r-sm: 12px;

  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + 16px);
  scrollbar-color: var(--line) var(--black);
}

body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }

::selection { background: var(--blood-2); color: var(--white); }
:focus-visible { outline: 2px solid var(--blood-text); outline-offset: 3px; border-radius: 4px; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--black); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--blood); }

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 100;
  background: var(--white);
  color: var(--black);
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Type ---------- */

h1, h2, h3 {
  font-family: var(--head);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 6vw, 5.6rem); }
h2 { font-size: clamp(2rem, 3.8vw, 3.3rem); }
h3 { font-size: clamp(1.3rem, 1.8vw, 1.6rem); line-height: 1.1; }

p { margin: 0; max-width: 64ch; text-wrap: pretty; }
.lede { font-size: clamp(1.08rem, 1.4vw, 1.25rem); line-height: 1.55; color: var(--dim); }
.center { text-align: center; margin-inline: auto; }
p.center { max-width: none; }
.red { color: var(--blood-lit); }

/* Wide-tracked caps: the tagline voice */
.tracked {
  font-family: var(--head);
  font-weight: 500;
  font-size: 0.86rem;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  line-height: 1.5;
}
.small-caps {
  font-family: var(--head);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ---------- Motion: content is visible by default, JS opts in ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(22px);
    filter: blur(6px);
    transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out), filter 0.9s var(--ease-out);
    transition-delay: calc(var(--d, 0) * 1ms);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; filter: none; }
}

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

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  height: 56px;
  padding: 0 32px;
  border: 0;
  border-radius: 999px;
  background: var(--grad);
  background-size: 160% 100%;
  background-position: 0% 0;
  color: var(--white);
  font-family: var(--head);
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 10px 30px -12px rgba(161, 14, 26, 0.7);
  transition: transform 160ms var(--ease-out), background-position 500ms var(--ease-out), box-shadow 300ms ease;
  -webkit-tap-highlight-color: transparent;
}
.btn i { font-size: 1.1em; transition: transform 300ms var(--ease-out); }
.btn:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background-position: 100% 0; box-shadow: 0 14px 40px -12px rgba(184, 18, 31, 0.85); }
  .btn:hover i { transform: translateX(4px); }
}
.btn--sm { height: 44px; padding: 0 22px; font-size: 0.78rem; }
.btn--ghost { background: transparent; box-shadow: inset 0 0 0 2px var(--white); }
@media (hover: hover) and (pointer: fine) {
  .btn--ghost:hover { background: var(--white); color: var(--black); box-shadow: inset 0 0 0 2px var(--white); }
}
.btn--light { background: var(--white); color: var(--black); box-shadow: none; }
@media (hover: hover) and (pointer: fine) {
  .btn--light:hover { background: var(--white); box-shadow: 0 14px 40px -14px rgba(0, 0, 0, 0.6); }
}
.btn[disabled] { opacity: 0.6; cursor: progress; }

.textlink {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--head);
  font-weight: 600;
  font-size: 0.86rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  padding-block: 6px;
  background: linear-gradient(var(--blood-2), var(--blood-2)) left bottom / 100% 2px no-repeat;
  transition: color 200ms ease;
}
.textlink i { transition: transform 300ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .textlink:hover { color: var(--blood-text); }
  .textlink:hover i { transform: translateX(4px); }
}

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  height: var(--nav-h);
  background: rgba(5, 4, 4, 0.94);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease;
}
@supports (backdrop-filter: blur(1px)) {
  .nav { background: rgba(5, 4, 4, 0.74); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%); }
}
.nav.is-stuck { border-bottom-color: var(--line); }
.nav__in {
  height: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}
.nav__logo { justify-self: start; display: block; }
.nav__logo img { height: 40px; width: auto; }
.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(22px, 3vw, 44px);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__links a {
  font-family: var(--head);
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color 200ms ease;
}
.nav__links a[aria-current="page"] { color: var(--blood-text); }
@media (hover: hover) and (pointer: fine) { .nav__links a:hover { color: var(--blood-text); } }
.nav__cta { justify-self: end; }
.nav__toggle {
  display: none;
  justify-self: end;
  width: 48px;
  height: 48px;
  margin-right: -8px;
  background: none;
  border: 0;
  font-size: 1.7rem;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.menu {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  z-index: 49;
  background: var(--black);
  padding: 40px var(--gutter);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-align: center;
  visibility: hidden;
  opacity: 0;
  transition: opacity 260ms ease, visibility 0s linear 260ms;
}
.menu.is-open { visibility: visible; opacity: 1; transition: opacity 260ms ease, visibility 0s; }
.menu ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.menu li a {
  display: block;
  font-family: var(--head);
  font-weight: 700;
  text-transform: uppercase;
  font-size: clamp(2.2rem, 11vw, 3.6rem);
  line-height: 1.2;
  text-decoration: none;
}
.menu li a[aria-current="page"] { color: var(--blood-text); }
.menu__foot { display: grid; gap: 22px; justify-items: center; }
.menu__foot .btn { width: 100%; }
.menu__contact { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 12px; }
.menu__socials { display: inline-flex; gap: 8px; flex: none; }
.menu__foot a.mail { text-decoration: none; color: var(--dim); font-size: 0.86rem; overflow-wrap: anywhere; }
.menu__social {
  width: 36px;
  height: 36px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--tile-2);
  color: var(--white);
  font-size: 1.2rem;
  text-decoration: none;
  transition: background 250ms ease, transform 160ms var(--ease-out);
}
.menu__social:active { transform: scale(0.95); }
@media (hover: hover) and (pointer: fine) { .menu__social:hover { background: var(--blood-2); } }

@media (max-width: 980px) {
  .nav__in > nav, .nav__cta { display: none; }
  .nav__in { grid-template-columns: 1fr auto; }
  .nav__toggle { display: inline-flex; }
  .nav__logo img { height: 34px; }
}
@media (min-width: 981px) { .menu { display: none; } }

/* ---------- Sections ---------- */

.section { padding-block: var(--section); }
.section--flush-top { padding-top: 0; }
.sec-head { display: grid; justify-items: center; text-align: center; gap: 16px; margin-bottom: clamp(40px, 5vw, 64px); }
.sec-head p { color: var(--dim); }

/* ---------- Home hero: the logo on a lit black stage ---------- */

.hero {
  position: relative;
  isolation: isolate;
  min-height: calc(100dvh - var(--nav-h));
  display: grid;
  place-items: center;
  text-align: center;
  overflow: hidden;
  padding-block: clamp(40px, 6vh, 80px);
}
/* Lava-lamp fluid: WebGL canvas; the CSS background is the no-WebGL fallback */
.hero__fluid {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  display: block;
  background:
    radial-gradient(38% 34% at 22% 72%, rgba(122, 8, 18, 0.75), transparent 70%),
    radial-gradient(30% 30% at 78% 30%, rgba(161, 14, 26, 0.55), transparent 70%),
    radial-gradient(44% 40% at 70% 88%, rgba(61, 3, 8, 0.9), transparent 70%),
    var(--black);
}
/* Keeps the logo and headline legible over the moving fluid */
.hero__shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(46% 52% at 50% 46%, rgba(5, 4, 4, 0.58), transparent 72%),
    linear-gradient(to bottom, rgba(5, 4, 4, 0.35), transparent 22%, transparent 78%, var(--black));
}
.hero__in { display: grid; justify-items: center; gap: clamp(18px, 2.6vh, 30px); max-width: 1120px; }
.hero__logo {
  width: auto;
  height: clamp(150px, 30vh, 300px);
  margin-bottom: clamp(6px, 1.4vh, 16px);
  filter: drop-shadow(0 18px 50px rgba(161, 14, 26, 0.45));
}
.hero__title { font-size: clamp(2rem, 4.4vw, 4rem); line-height: 1.02; letter-spacing: 0.005em; }
.hero__title .line { display: block; }
.hero__sub { color: var(--white); }
.hero__actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 16px 28px; margin-top: 4px; }

@media (prefers-reduced-motion: no-preference) {
  /* No blur on the logo: iOS Safari can freeze a large filtered image on its blurred first frame */
  .js .hero__logo { opacity: 0; transform: scale(0.94); transition: opacity 1.1s var(--ease-out), transform 1.4s var(--ease-out); }
  .js .is-loaded .hero__logo { opacity: 1; transform: none; }
  .js .hero__title .line { opacity: 0; transform: translateY(24px); filter: blur(8px); transition: opacity 1s var(--ease-out) 300ms, transform 1s var(--ease-out) 300ms, filter 1s var(--ease-out) 300ms; }
  .js .is-loaded .hero__title .line { opacity: 1; transform: none; filter: none; }
  .js .is-loaded .hero__title .line:nth-child(2) { transition-delay: 420ms; }
  .js .hero__fade { opacity: 0; transition: opacity 1s ease 800ms; }
  .js .is-loaded .hero__fade { opacity: 1; }
}
@media (max-width: 600px) { .hero__logo { height: clamp(140px, 24vh, 200px); } }

/* ---------- Clients logo strip: drifts on its own, scrolls sideways by hand ---------- */

.clients { padding-block: clamp(48px, 6vw, 80px); border-block: 1px solid var(--line); }
.clients h2 { margin-bottom: clamp(24px, 3vw, 36px); text-align: center; }
.marquee {
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee::-webkit-scrollbar { display: none; }
.marquee.is-dragging { cursor: grabbing; user-select: none; }
.marquee:focus-visible { outline-offset: -2px; }
.marquee__track { display: flex; width: max-content; list-style: none; margin: 0; padding: 0; }
.marquee__track li {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(150px, 15vw, 210px);
  height: 92px;
  padding: 0 26px;
}
.marquee__track img {
  max-height: 44px;
  max-width: 100%;
  width: auto;
  object-fit: contain;
  pointer-events: none;
  /* Every client logo renders solid white: dark marks invert to white,
     white backgrounds invert to black and drop out under screen blending */
  filter: grayscale(1) invert(1) brightness(1.7) contrast(1.9);
  mix-blend-mode: screen;
  opacity: 0.92;
}
.marquee__track img.tall { max-height: 64px; }
/* Salesforce: light cloud on a transparent ground, so push the cloud to white
   and let its lettering read as a cut-out */
.marquee__track img.keep { filter: grayscale(1) invert(1) brightness(2.4) contrast(1.5); mix-blend-mode: normal; opacity: 0.92; }

/* ---------- Tiles (product-card style) ---------- */

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
.tile {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--tile);
  border-radius: var(--r);
  overflow: hidden;
  isolation: isolate;
  text-decoration: none;
  transition: transform 400ms var(--ease-out);
}
.tile__head { padding: clamp(24px, 2.4vw, 32px) 24px 0; text-align: center; }
.tile__head h3 { font-size: clamp(1.5rem, 2.1vw, 1.9rem); }
.tile__media {
  position: relative;
  isolation: isolate;
  margin: 22px 24px 0;
  border-radius: var(--r-sm);
  overflow: hidden;
  aspect-ratio: 4 / 3;
}
.tile__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out); }
.tile__body { padding: 22px 24px 28px; display: grid; gap: 18px; flex: 1; align-content: start; }
.tile__body p { color: var(--dim); font-size: 0.98rem; }
.tile__list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tile__list li { background: var(--tile-2); border-radius: 999px; padding: 6px 14px; font-size: 0.86rem; }
.tile__glow {
  position: absolute;
  inset: auto 0 0 0;
  height: 60%;
  z-index: -1;
  background: radial-gradient(60% 80% at 50% 100%, rgba(122, 8, 18, 0.55), transparent 70%);
  opacity: 0.55;
  transition: opacity 500ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .tile:hover { transform: translateY(-4px); }
  .tile:hover .tile__media img { transform: scale(1.05); }
  .tile:hover .tile__glow { opacity: 1; }
}
@media (max-width: 900px) { .tiles { grid-template-columns: 1fr; } }

/* ---------- Stat tiles ---------- */

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 20px); list-style: none; margin: 0; padding: 0; }
.stat {
  background: var(--tile);
  border-radius: var(--r);
  padding: clamp(28px, 3vw, 40px) 20px;
  display: grid;
  justify-items: center;
  align-content: start;
  text-align: center;
  gap: 12px;
}
.stat__fig { font-family: var(--head); font-weight: 600; font-size: clamp(3rem, 5.2vw, 4.6rem); line-height: 1; letter-spacing: -0.01em; }
.stat__label { font-family: var(--head); font-weight: 700; text-transform: uppercase; font-size: clamp(1rem, 1.3vw, 1.2rem); line-height: 1.15; }
.stat p { color: var(--dim); font-size: 0.92rem; }
.stat small { color: var(--faint); font-size: 0.78rem; }
.sources { margin: 24px auto 0; text-align: center; color: var(--faint); font-size: 0.84rem; }
@media (max-width: 900px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .stats { grid-template-columns: 1fr; } }

/* ---------- Full-bleed banner ---------- */

.banner {
  position: relative;
  isolation: isolate;
  min-height: min(92vh, 820px);
  display: grid;
  place-items: end center;
  text-align: center;
  overflow: hidden;
  padding: clamp(80px, 10vw, 140px) var(--gutter) clamp(56px, 7vw, 96px);
}
.banner__bg { position: absolute; inset: 0; z-index: -1; }
.banner__bg img { width: 100%; height: 100%; object-fit: cover; }
.banner__bg--portrait img { object-position: 50% 22%; }
.banner__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, var(--black) 0%, rgba(5, 4, 4, 0.1) 22%, rgba(5, 4, 4, 0.2) 50%, rgba(5, 4, 4, 0.92) 100%),
    linear-gradient(0deg, rgba(90, 6, 14, 0.4), rgba(90, 6, 14, 0.4));
}
.banner__in { display: grid; justify-items: center; gap: clamp(24px, 3vw, 36px); }
.banner__title { font-size: clamp(3rem, 9vw, 8.2rem); line-height: 0.92; max-width: 12ch; }

/* ---------- Case files ---------- */

.cases { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
.case { grid-column: span 4; position: relative; display: block; border-radius: var(--r); overflow: hidden; text-decoration: none; isolation: isolate; background: var(--tile); }
.case--wide { grid-column: span 8; }
.case__img { aspect-ratio: 4 / 5; }
.case--wide .case__img { aspect-ratio: auto; height: 100%; }
.case__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 900ms var(--ease-out); }
.case__img { position: relative; overflow: hidden; }
/* Looping film clip over the still; fades in only once it is actually playing */
.case__clip {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
  transition: opacity 700ms ease;
  overflow: hidden;
  background: transparent;
}
.case__clip.is-playing { opacity: 1; }
/* YouTube's player is 16:9; script sizes it to cover the card, CSS centres and crops it */
.case__clip iframe { position: absolute; top: 50%; left: 50%; translate: -50% -50%; border: 0; pointer-events: none; }
.case__shade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(to top, rgba(5, 4, 4, 0.95) 0%, rgba(5, 4, 4, 0.35) 45%, transparent 70%); }
.case__text { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; padding: clamp(20px, 2.4vw, 32px); display: grid; gap: 8px; }
.case__title { font-family: var(--head); font-weight: 700; text-transform: uppercase; font-size: clamp(1.5rem, 2.4vw, 2.2rem); line-height: 1.02; }
.case--wide .case__title { font-size: clamp(1.9rem, 3.4vw, 3rem); }
.case__meta { color: var(--dim); font-size: 0.92rem; }
.case__meta strong { color: var(--white); font-weight: 600; }
.case__arrow {
  position: absolute;
  z-index: 2;
  top: 18px;
  right: 18px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(5, 4, 4, 0.6);
  font-size: 1.2rem;
  transition: background 300ms ease, transform 300ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .case:hover .case__img img { transform: scale(1.05); }
  .case:hover .case__arrow { background: var(--blood-2); transform: rotate(-45deg); }
}
@media (max-width: 900px) {
  .case, .case--wide { grid-column: 1 / -1; }
  .case--wide .case__img { aspect-ratio: 4 / 5; height: auto; }
}

/* Home page: three featured cards in one row, about two-thirds the usual size */
.cases--trio { max-width: 66.667%; margin-inline: auto; }
.cases--trio .case__title { font-size: clamp(1.1rem, 1.6vw, 1.5rem); }
.cases--trio .case__meta { font-size: 0.82rem; }
.cases--trio .case__text { padding: clamp(14px, 1.6vw, 22px); }
.cases--trio .case__arrow { top: 12px; right: 12px; width: 38px; height: 38px; font-size: 1rem; }
@media (max-width: 900px) {
  .cases--trio { max-width: 480px; }
  .cases--trio .case__img { aspect-ratio: 6 / 5; }
}

/* Work page: square cards, two per row, sized so a full row fits in one screen */
.cases--squares { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: min(100%, calc((100svh - var(--nav-h) - 48px) * 2 + 22px), 1040px); margin-inline: auto; }
.cases--squares .case, .cases--squares .case--wide { grid-column: auto; }
.cases--squares .case:last-child:nth-child(odd) { grid-column: 1 / -1; justify-self: center; width: calc(50% - clamp(14px, 1.6vw, 22px) / 2); }
@media (max-width: 600px) { .cases--squares .case:last-child:nth-child(odd) { width: calc(50% - 5px); } }
.cases--squares .case__img, .cases--squares .case--wide .case__img { aspect-ratio: 1 / 1; height: auto; }
.cases--squares .case__title, .cases--squares .case--wide .case__title { font-size: clamp(1rem, 2.2vw, 1.9rem); }
@media (max-width: 600px) {
  .cases--squares { gap: 10px; }
  .cases--squares .case__text { padding: 12px; gap: 4px; }
  .cases--squares .case__meta { font-size: 0.72rem; line-height: 1.3; }
  .cases--squares .case__arrow { top: 8px; right: 8px; width: 30px; height: 30px; font-size: 0.85rem; }
}

/* ---------- Founder ---------- */

.founder { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.founder__img { position: sticky; top: calc(var(--nav-h) + 24px); }
@media (max-width: 900px) { .founder__img { position: static; } }
.founder__img { margin: 0; border-radius: var(--r); overflow: hidden; }
.founder__img img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 25%; }
.founder__copy { display: grid; gap: 26px; }
.founder__copy h2 { font-size: clamp(2.2rem, 4.4vw, 3.8rem); }
.founder__bio { display: grid; gap: 16px; color: var(--dim); font-size: clamp(0.98rem, 1.1vw, 1.06rem); line-height: 1.65; }
.founder__bio p { max-width: 68ch; }
.ledger { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.ledger li { display: flex; justify-content: space-between; gap: 20px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--dim); }
.ledger li strong { color: var(--white); font-weight: 600; text-align: right; }
@media (max-width: 900px) { .founder { grid-template-columns: 1fr; } }

/* ---------- Follow ---------- */

.follow { text-align: center; }
.socials { display: flex; justify-content: center; gap: 18px; margin: 28px 0 clamp(40px, 5vw, 64px); }
.socials a {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--tile-2);
  font-size: 1.9rem;
  color: var(--blood-text);
  text-decoration: none;
  transition: background 300ms ease, color 300ms ease, transform 160ms var(--ease-out);
}
.socials a:active { transform: scale(0.95); }
@media (hover: hover) and (pointer: fine) { .socials a:hover { background: var(--blood-2); color: var(--white); } }
.gallery-strip { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.gallery-strip figure { margin: 0; aspect-ratio: 4 / 5; border-radius: var(--r-sm); overflow: hidden; background: var(--tile); }
.gallery-strip img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .gallery-strip figure:hover img { transform: scale(1.06); } }
@media (max-width: 900px) { .gallery-strip { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- Closing CTA ---------- */

.close {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--r);
  background: var(--grad);
  padding: clamp(56px, 8vw, 112px) clamp(24px, 5vw, 80px);
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 24px;
}
.close::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(60% 90% at 50% 120%, rgba(255, 255, 255, 0.14), transparent 70%);
}
.close h2 { font-size: clamp(2.2rem, 5.4vw, 4.8rem); max-width: 16ch; }
.close p { color: rgba(246, 242, 238, 0.88); font-size: clamp(1.02rem, 1.3vw, 1.18rem); }

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

.foot { padding-block: clamp(64px, 8vw, 104px) 32px; }
.foot__grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr) minmax(0, 3fr) minmax(0, 3fr); gap: 40px; }
.foot__grid > div:nth-child(4) a { white-space: nowrap; }
.foot__logo img { width: 190px; height: auto; }
.foot h2 { font-size: 0.8rem; letter-spacing: 0.3em; font-weight: 600; color: var(--faint); margin-bottom: 18px; line-height: 1.3; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.foot li { min-width: 0; overflow-wrap: break-word; }
.foot__grid > * { min-width: 0; }
.foot a { text-decoration: none; transition: color 200ms ease; }
.foot a:hover { color: var(--blood-text); }
.foot a i { margin-right: 8px; }
.foot__base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: clamp(56px, 7vw, 88px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 0.85rem;
}
@media (max-width: 900px) {
  .foot__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot__brand { grid-column: 1 / -1; }
}
@media (max-width: 900px) { .foot__grid > div:nth-child(4) { grid-column: 1 / -1; } }
@media (max-width: 600px) {
  .foot__grid > div:nth-child(3) { grid-column: 1 / -1; grid-row: 2; }
  .foot__grid > div:nth-child(4) { grid-row: 4; }
}

/* ---------- Inner page header ---------- */

.phead {
  position: relative;
  isolation: isolate;
  text-align: center;
  display: grid;
  justify-items: center;
  gap: 22px;
  padding-top: clamp(64px, 9vw, 128px);
  padding-bottom: clamp(48px, 6vw, 88px);
}
.phead::before {
  content: "";
  position: absolute;
  z-index: -1;
  left: 50%;
  top: 0;
  width: min(1100px, 100%);
  height: 100%;
  translate: -50% 0;
  background: radial-gradient(50% 60% at 50% 30%, rgba(122, 8, 18, 0.38), transparent 70%);
  pointer-events: none;
}
.phead h1 { font-size: clamp(2.6rem, 7vw, 6.2rem); }
.phead .lede { max-width: 52ch; }

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

.pillar {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: center;
  padding-block: clamp(40px, 5vw, 72px);
}
.pillar__img { margin: 0; border-radius: var(--r); overflow: hidden; }
.pillar__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.pillar__copy { display: grid; gap: 24px; }
.pillar__copy h2 { font-size: clamp(2.4rem, 5vw, 4.4rem); }
.deliv { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.deliv li { background: var(--tile); border-radius: var(--r-sm); padding: 16px 20px; display: grid; gap: 2px; }
.deliv strong { font-family: var(--head); font-weight: 600; font-size: 1.05rem; letter-spacing: 0.02em; }
.deliv span { color: var(--dim); font-size: 0.95rem; }
.pillar--flip .pillar__img { order: 2; }
@media (max-width: 900px) {
  .pillar { grid-template-columns: 1fr; }
  .pillar--flip .pillar__img { order: 0; }
}

.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 20px); list-style: none; margin: 0; padding: 0; }
.steps li { background: var(--tile); border-radius: var(--r); padding: 28px 24px; display: grid; gap: 10px; align-content: start; }
.steps h3 { font-size: 1.35rem; }
.steps p { color: var(--dim); font-size: 0.96rem; }
@media (max-width: 900px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

/* ---------- Case study ---------- */

.case-hero { margin: 0 auto; }
.case-hero img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: 50% 25%; border-radius: var(--r); background: var(--tile); }
.case-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.case-facts { position: sticky; top: calc(var(--nav-h) + 24px); margin: 0; background: var(--tile); border-radius: var(--r); padding: 8px 24px; }
.case-facts div { padding: 16px 0; border-bottom: 1px solid var(--line); display: grid; gap: 4px; }
.case-facts div:last-child { border-bottom: 0; }
.case-facts dt { color: var(--faint); font-family: var(--head); font-weight: 600; font-size: 0.74rem; letter-spacing: 0.24em; text-transform: uppercase; }
.case-facts dd { margin: 0; }
.case-body { display: grid; gap: 24px; font-size: clamp(1.04rem, 1.25vw, 1.16rem); line-height: 1.65; }
.case-body > p { color: var(--dim); }
.case-body > p:first-child { color: var(--white); }
.case-body h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin-top: 20px; }
.results { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.results li { background: var(--tile); border-radius: var(--r); padding: 24px 22px; display: grid; gap: 8px; align-content: start; }
.results .stat__fig { font-size: clamp(2.4rem, 4vw, 3.4rem); }
.results .note { font-family: var(--head); font-weight: 700; text-transform: uppercase; font-size: 1.15rem; line-height: 1.2; }
.results span:last-child { color: var(--dim); font-size: 0.95rem; }
.gallery { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 18px); }
.gallery figure { margin: 0; border-radius: var(--r); overflow: hidden; background: var(--tile); }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.g-7 { grid-column: span 7; } .g-5 { grid-column: span 5; } .g-6 { grid-column: span 6; } .g-12 { grid-column: span 12; }
.gallery .tall { aspect-ratio: 4 / 5; } .gallery .wide { aspect-ratio: 3 / 2; }
@media (max-width: 700px) { .gallery > * { grid-column: 1 / -1; } }
.g-4 { grid-column: span 4; }
@media (max-width: 700px) { .gallery > .g-4 { grid-column: span 6; } }
.video { position: relative; aspect-ratio: 16 / 9; background: var(--tile); border-radius: var(--r); overflow: hidden; }
.video iframe, .video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.video__poster { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; cursor: pointer; background: #000; }
.video__poster img { width: 100%; height: 100%; object-fit: cover; opacity: 0.6; transition: opacity 300ms ease; }
.video__poster span {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 60px;
  padding: 0 30px;
  border-radius: 999px;
  background: var(--grad);
  font-family: var(--head);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: transform 160ms var(--ease-out);
}
.video__poster:hover img { opacity: 0.85; }
.video__poster:active span { transform: scale(0.97); }
.next {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 14px;
  padding: clamp(48px, 6vw, 88px) 24px;
  text-decoration: none;
  border-radius: var(--r);
  background: var(--tile);
  transition: background 400ms ease;
}
.next__title { font-family: var(--head); font-weight: 700; text-transform: uppercase; font-size: clamp(2.2rem, 5.6vw, 4.6rem); line-height: 1; }
.next i { font-size: 2rem; transition: transform 400ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .next:hover { background: var(--blood); }
  .next:hover i { transform: translateX(8px); }
}
@media (max-width: 900px) {
  .case-grid { grid-template-columns: 1fr; }
  .case-facts { position: static; }
}

/* ---------- About ---------- */

.statement { font-family: var(--head); font-weight: 700; text-transform: uppercase; font-size: clamp(2.2rem, 5.4vw, 4.6rem); line-height: 1.02; text-align: center; max-width: 18ch; margin: 0 auto; text-wrap: balance; }
.statement q { quotes: none; display: block; font-weight: 500; font-size: 0.4em; letter-spacing: 0.2em; line-height: 1.5; color: var(--dim); margin-bottom: 1.2em; }

.bio { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.bio__img { margin: 0; border-radius: var(--r); overflow: hidden; position: sticky; top: calc(var(--nav-h) + 24px); }
.bio__img img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 20%; }
.bio__copy { display: grid; gap: 22px; font-size: clamp(1.04rem, 1.25vw, 1.16rem); }
.bio__copy > p { color: var(--dim); }
.roster { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0; }
.roster li { background: var(--tile-2); border-radius: 999px; padding: 8px 16px; font-size: 0.92rem; }
@media (max-width: 900px) { .bio { grid-template-columns: 1fr; } .bio__img { position: static; } }

.team { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(12px, 1.4vw, 20px); list-style: none; margin: 0; padding: 0; }
.team li { background: var(--tile); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; }
.team img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: 50% 25%; }
.team__body { padding: 20px 20px 24px; display: grid; gap: 8px; align-content: start; }
.team h3 { font-size: 1.3rem; }
.team .role { color: var(--blood-text); font-size: 0.88rem; font-weight: 600; }
.team p { color: var(--dim); font-size: 0.93rem; }
.team .handle { color: var(--faint); font-size: 0.9rem; text-decoration: none; }
.team a.handle:hover { color: var(--white); }
@media (max-width: 1100px) { .team { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .team { grid-template-columns: 1fr 1fr; } }
@media (max-width: 420px) { .team { grid-template-columns: 1fr; } }

.help { list-style: none; margin: 0 auto; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; max-width: 1040px; }
.help li { background: var(--tile); border-radius: var(--r-sm); padding: 20px 22px; font-size: 1.05rem; display: flex; gap: 14px; align-items: flex-start; }
.help li i { color: var(--blood-text); font-size: 1.3rem; margin-top: 2px; }
@media (max-width: 800px) { .help { grid-template-columns: 1fr; } }

.faq { display: grid; gap: 10px; max-width: 920px; margin-inline: auto; }
.faq details { background: var(--tile); border-radius: var(--r); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 22px 26px;
  font-family: var(--head);
  font-weight: 700;
  text-transform: uppercase;
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
  line-height: 1.25;
  border-radius: var(--r);
  transition: color 200ms ease;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary i { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--tile-2); display: grid; place-items: center; font-size: 1.1rem; transition: transform 300ms var(--ease-out), background 300ms ease; }
.faq details[open] summary i { transform: rotate(45deg); background: var(--blood-2); }
.faq summary:hover { color: var(--blood-text); }
.faq details > div { padding: 0 26px 24px; color: var(--dim); max-width: 70ch; }

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

.contact { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(16px, 2vw, 24px); align-items: start; }
.contact__aside { display: grid; gap: 12px; position: sticky; top: calc(var(--nav-h) + 24px); }
.info { background: var(--tile); border-radius: var(--r); padding: 22px 24px; display: grid; gap: 6px; }
.info .small-caps { color: var(--faint); }
.info a { text-decoration: none; font-weight: 600; overflow-wrap: anywhere; }
.info a:hover { color: var(--blood-text); }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } .contact__aside { position: static; } }

.form-wrap { background: var(--tile); border-radius: var(--r); padding: clamp(22px, 3.4vw, 44px); }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 20px; }
.field { display: grid; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: 0.95rem; }
.field label .opt { color: var(--faint); font-weight: 400; }
.field input,
.field textarea {
  width: 100%;
  background: var(--black);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 14px 16px;
  font-size: 1rem;
  color: var(--white);
  caret-color: var(--blood-text);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.field textarea { min-height: 170px; resize: vertical; line-height: 1.5; }
.field input::placeholder, .field textarea::placeholder { color: #8a817b; }
.field input:hover, .field textarea:hover { border-color: #4a4242; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--blood-2); box-shadow: 0 0 0 3px rgba(161, 14, 26, 0.35); }
.field .hint { color: var(--faint); font-size: 0.86rem; }
.field .err { color: var(--blood-text); font-size: 0.88rem; display: none; }
.field.is-invalid input, .field.is-invalid textarea { border-color: var(--blood-text); }
.field.is-invalid .err { display: block; }
.check { grid-column: 1 / -1; display: flex; gap: 14px; align-items: flex-start; cursor: pointer; color: var(--dim); font-size: 0.95rem; }
.check input { appearance: none; flex: none; width: 22px; height: 22px; margin: 2px 0 0; border: 2px solid var(--faint); border-radius: 6px; background: transparent; cursor: pointer; display: grid; place-items: center; transition: background 150ms ease, border-color 150ms ease; }
.check input::after { content: ""; width: 10px; height: 6px; border-left: 2px solid var(--white); border-bottom: 2px solid var(--white); transform: rotate(-45deg) scale(0); margin-top: -2px; transition: transform 150ms var(--ease-out); }
.check input:checked { background: var(--blood-2); border-color: var(--blood-2); }
.check input:checked::after { transform: rotate(-45deg) scale(1); }
.check.is-invalid input { border-color: var(--blood-text); }
.form__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 18px 24px; }
.form__status { font-size: 0.98rem; }
.form__status[data-state="error"] { color: var(--blood-text); }
.form__status a { color: var(--white); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.sent { display: none; text-align: center; padding: clamp(24px, 4vw, 56px) 0; }
.sent h2 { margin-bottom: 14px; }
.sent p { color: var(--dim); margin-inline: auto; }
.form-wrap.is-sent .form { display: none; }
.form-wrap.is-sent .sent { display: block; }
@media (max-width: 640px) { .form { grid-template-columns: 1fr; } .form__foot .btn { width: 100%; } }

/* ---------- 404 ---------- */
.lost { min-height: calc(100dvh - var(--nav-h)); display: grid; place-content: center; justify-items: center; text-align: center; gap: 28px; padding-block: 64px; }

/* ---------- Utilities ---------- */
.mt-l { margin-top: clamp(40px, 5vw, 64px); }
.sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

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