/* ==========================================================
   Denise Ventura — Senior Product Designer
   Visual system: "mission control for complex data"
   ========================================================== */

:root {
  --bg: #04050d;
  --bg-2: #0a0d20;
  --bg-3: #12163a;
  --fg: #eef0f6;
  --fg-2: #b9bfd3;
  --muted: #7e86a0;
  --line: rgba(238, 240, 246, 0.10);
  --line-2: rgba(238, 240, 246, 0.22);
  --red: #ff3b2e;
  --red-2: #e02b1f;
  --paper: #eef1f4;
  --red-ink: #cc2617; /* brand red, deepened for small text on light backgrounds (WCAG AA 4.5:1) */
  --paper-2: #e3e7ec;
  --ink: #0a0d1c;
  --ink-2: #4c5468;
  --ink-line: rgba(10, 13, 28, 0.12);
  --card: #fbfcfd;
  --sky: #2f46d6;
  --r: 26px;
  --night: var(--bg);

  --gut: clamp(24px, 5vw, 96px);
  --nav-h: 68px;

  --display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --sans: "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --ease: cubic-bezier(0.19, 0.8, 0.12, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

img { display: block; max-width: 100%; height: auto; } /* width/height attributes reserve space while loading; CSS still sizes the image */
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, p, figure, blockquote { margin: 0; }
em { font-style: normal; color: var(--red); }

::selection { background: var(--red); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

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

.mono {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.label {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-2);
  display: flex;
  align-items: center;
  gap: 10px;
}
.label::before {
  content: "";
  width: 18px;
  height: 1px;
  background: var(--red);
  flex: none;
}
.hero-loc::before { display: none; }

/* ---------- Display type ---------- */
.h1, .h2, .mega, .statement, .hero-title, .cta-title, .case-title, .wordmark {
  font-family: var(--display);
  font-stretch: 118%;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 0.98;
}
.h1 { font-size: clamp(40px, 6.4vw, 112px); font-size: round(nearest, clamp(40px, 6.4vw, 112px), 8px); }
.h2 { font-size: clamp(32px, min(4.2vw, 7.4vh), 72px); font-size: round(nearest, clamp(32px, min(4.2vw, 7.4vh), 72px), 8px); }

/* ---------- Buttons (Denise Sharp Design) ---------- */
.btn {
  --h: 48px;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  height: var(--h);
  padding: 0 20px;
  background: var(--fg);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.4s var(--ease);
}
.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--red);
  transform: translateY(101%);
  transition: transform 0.5s var(--ease);
  z-index: -1;
}
.btn:hover::after { transform: none; }
.btn .arr { font-style: normal; transition: transform 0.5s var(--ease); }
.btn:hover .arr { transform: translateX(4px); }
.btn[href="#work"]:hover .arr { transform: translateY(3px); }
.btn-sm { --h: 36px; padding: 0 14px; font-size: 12px; }
.btn-lg { --h: 58px; padding: 0 26px; font-size: 13px; }
.btn:focus-visible { outline-offset: 4px; }

.ulink {
  position: relative;
  display: inline-block;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size 0.5s var(--ease), color 0.3s;
  padding-bottom: 2px;
}
.ulink:hover {
  color: var(--red);
  background-image: linear-gradient(var(--red), var(--red));
  animation: ulink 0.6s var(--ease);
}
@keyframes ulink {
  0% { background-size: 100% 1px; background-position: 100% 100%; }
  45% { background-size: 0% 1px; background-position: 100% 100%; }
  46% { background-position: 0 100%; }
  100% { background-size: 100% 1px; background-position: 0 100%; }
}

/* ---------- Frame corners (HUD brackets) ---------- */
.frame-corner {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 0 solid var(--fg);
  opacity: 0.55;
  pointer-events: none;
  z-index: 3;
}
.frame-corner.tl { top: 0; left: 0; border-top-width: 1px; border-left-width: 1px; }
.frame-corner.tr { top: 0; right: 0; border-top-width: 1px; border-right-width: 1px; }
.frame-corner.bl { bottom: 0; left: 0; border-bottom-width: 1px; border-left-width: 1px; }
.frame-corner.br { bottom: 0; right: 0; border-bottom-width: 1px; border-right-width: 1px; }

/* ==========================================================
   NAV
   ========================================================== */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: var(--gut);
  transition: background 0.4s, backdrop-filter 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(4, 5, 13, 0.72);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--line);
}
.nav-progress {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  pointer-events: none;
}
.nav-progress span {
  display: block;
  height: 100%;
  background: var(--red);
  transform-origin: 0 50%;
  transform: scaleX(var(--sp, 0));
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--display);
  font-stretch: 118%;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.brand-mark {
  width: 12px;
  height: 12px;
  background: var(--red);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0 60%, 40% 60%, 40% 40%, 0 40%);
  transition: transform 0.6s var(--ease);
}
.brand:hover .brand-mark { transform: rotate(90deg); }
.nav-right { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 36px); }
.nav-link {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-2);
  position: relative;
  transition: color 0.3s;
}
.nav-link::before {
  content: "[";
  position: absolute;
  left: -10px;
  opacity: 0;
  color: var(--red);
  transition: opacity 0.3s, transform 0.3s var(--ease);
  transform: translateX(4px);
}
.nav-link::after {
  content: "]";
  position: absolute;
  right: -10px;
  opacity: 0;
  color: var(--red);
  transition: opacity 0.3s, transform 0.3s var(--ease);
  transform: translateX(-4px);
}
.nav-link:hover { color: var(--fg); }
.nav-link:hover::before, .nav-link:hover::after { opacity: 1; transform: none; }
.nav-clock { color: var(--muted); font-size: 12px; }
.nav-clock span { color: var(--fg-2); }

/* ==========================================================
   HERO
   ========================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  overflow: hidden;
  background: var(--bg); /* same as the How section */
  cursor: crosshair;
}
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(4,5,13,0.85) 0%, rgba(4,5,13,0.35) 45%, rgba(4,5,13,0) 70%),
    linear-gradient(0deg, rgba(4,5,13,0.95) 0%, rgba(4,5,13,0) 38%),
    linear-gradient(180deg, rgba(4,5,13,0.7) 0%, rgba(4,5,13,0) 20%);
  pointer-events: none;
}
.hero > .frame-corner { width: 22px; height: 22px; opacity: 0.4; }
.hero > .frame-corner.tl { top: calc(var(--nav-h) + 8px); left: var(--gut); }
.hero > .frame-corner.tr { top: calc(var(--nav-h) + 8px); right: var(--gut); }
.hero > .frame-corner.bl { bottom: 20px; left: var(--gut); }
.hero > .frame-corner.br { bottom: 20px; right: var(--gut); }

.hud {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s;
  z-index: 1;
}
.hero.is-hover .hud { opacity: 1; }
.hud-x, .hud-y {
  position: absolute;
  background: rgba(236, 235, 230, 0.16);
}
.hud-x { left: 0; right: 0; height: 1px; top: 0; transform: translateY(var(--my, 50vh)); }
.hud-y { top: 0; bottom: 0; width: 1px; left: 0; transform: translateX(var(--mx, 50vw)); }
.hud-read {
  position: absolute;
  top: 0; left: 0;
  transform: translate(calc(var(--mx, 50vw) + 14px), calc(var(--my, 50vh) + 12px));
  font-size: 12px;
  color: var(--fg-2);
  white-space: nowrap;
  display: flex;
  gap: 10px;
}
.hud-read b { font-weight: 400; }
.hud-read b:first-child { color: var(--red); }

.hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: calc(var(--nav-h) + clamp(28px, 6vh, 64px));
  padding-bottom: clamp(32px, 6vh, 64px);
  pointer-events: none;
}
.hero-inner a, .hero-inner button { pointer-events: auto; }
.hero-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
  padding-inline: 34px;
}
.hero-loc { gap: 10px; }
.hero-loc .coords { color: var(--muted); margin-left: 6px; }
.live {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 0 rgba(255, 59, 46, 0.6);
  animation: live 2s infinite;
}
@keyframes live {
  0% { box-shadow: 0 0 0 0 rgba(255, 59, 46, 0.55); }
  70% { box-shadow: 0 0 0 10px rgba(255, 59, 46, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 59, 46, 0); }
}

.hero-title {
  display: flex;
  flex-direction: column;
  /* sized so the widest line ("DESIGNER") sits around the middle of the hero on desktop */
  font-size: clamp(56px, min(8vw, 19.5vh), 136px); font-size: round(down, clamp(56px, min(8vw, 19.5vh), 136px), 8px);
  font-weight: 700;
  font-stretch: 125%;
  text-transform: uppercase;
  letter-spacing: -0.035em;
  line-height: 0.86;
  margin-block: clamp(24px, 5vh, 56px);
}
.hero-title .ln { display: block; }
.hero-title .accent { color: var(--red); }
.hero-title .ln:first-child { font-size: min(72px, 1em); } /* "Senior": 72px, never bigger than the rest of the title */

.hero-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 28px 48px;
}
.hero-cta { display: flex; align-items: center; gap: 28px; }
.roles {
  font-family: var(--display);
  font-stretch: 110%;
  font-size: clamp(18px, 1.7vw, 26px); font-size: round(nearest, clamp(18px, 1.7vw, 26px), 1px);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.01em;
  border-left: 1px solid var(--red);
  padding-left: 18px;
}
.scroll-cue {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
}
.scroll-bar {
  width: 1px;
  height: 44px;
  background: var(--line-2);
  position: relative;
  overflow: hidden;
}
.scroll-bar::after {
  content: "";
  position: absolute;
  left: 0; top: -40%;
  width: 100%; height: 40%;
  background: var(--red);
  animation: drip 2.2s var(--ease-io) infinite;
}
@keyframes drip { to { top: 100%; } }

/* ==========================================================
   HOW — pinned horizontal panels
   ========================================================== */
.how {
  position: relative;
  height: 400vh; /* 100vh per panel, 4 panels */
  background: var(--bg);
  border-top: 1px solid var(--line);
}
.how-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: var(--bg);
}
.how-track {
  display: flex;
  height: 100%;
  width: max-content;
  will-change: transform;
}
.panel {
  position: relative;
  flex: none;
  width: var(--vw, 100vw);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: clamp(24px, 5vh, 56px);
  padding: calc(var(--nav-h) + clamp(28px, 7vh, 72px)) var(--gut) calc(84px + clamp(12px, 4vh, 40px));
  border-right: 1px solid var(--line);
  overflow: hidden;
}
.panel-num {
  position: absolute;
  right: calc(var(--gut) - 0.06em);
  top: calc(var(--nav-h) - 0.12em);
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(136px, 26vw, 424px); font-size: round(nearest, clamp(136px, 26vw, 424px), 8px);
  line-height: 1;
  letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(236, 235, 230, 0.09);
  pointer-events: none;
  transform: translateX(var(--par, 0px));
}
.panel-head { position: relative; display: grid; gap: 64px; max-width: 1100px; }

.statement {
  font-size: clamp(40px, min(6.6vw, 11vh), 120px); font-size: round(nearest, clamp(40px, min(6.6vw, 11vh), 120px), 8px);
  font-weight: 600;
  max-width: 17ch;
}
.lede {
  font-size: clamp(18px, 1.5vw, 24px); font-size: round(nearest, clamp(18px, 1.5vw, 24px), 1px);
  line-height: 1.4;
  color: var(--fg-2);
  max-width: 36ch;
}
.panel-intro .panel-head { gap: clamp(20px, 4vh, 40px); align-self: stretch; margin-top: auto; }
.swipe {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--fg-2);
}
.swipe-line {
  position: relative;
  width: 120px;
  height: 1px;
  background: var(--line-2);
  overflow: hidden;
}
.swipe-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--red);
  transform: translateX(-100%);
  animation: sweep 2.4s var(--ease-io) infinite;
}
@keyframes sweep { 60%, 100% { transform: translateX(100%); } }

.cells {
  position: relative;
  display: grid;
  border-top: 1px solid var(--line-2);
}
.cells li {
  position: relative;
  padding: clamp(14px, 2.4vh, 26px) clamp(14px, 1.6vw, 28px) clamp(14px, 2.4vh, 26px) 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.4s;
}
.cells li::before {
  content: "";
  position: absolute;
  left: 0; top: -1px;
  height: 1px;
  width: 0;
  background: var(--red);
  transition: width 0.7s var(--ease);
}
.cells li:hover::before { width: 100%; }
.cells h3 {
  font-family: var(--display);
  font-stretch: 110%;
  font-size: clamp(17px, 1.45vw, 23px); font-size: round(nearest, clamp(17px, 1.45vw, 23px), 1px);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 8px;
  hyphens: manual;
}
.cells p { color: var(--fg-2); font-size: clamp(14px, 1.05vw, 16px); font-size: round(nearest, clamp(14px, 1.05vw, 16px), 1px); line-height: 1.45; max-width: 34ch; }
.cell-idx { display: block; color: var(--red); font-size: 12px; margin-bottom: clamp(10px, 2vh, 22px); }

.cells-6 { grid-template-columns: repeat(3, 1fr); column-gap: clamp(16px, 2vw, 32px); }
.cells-4 { grid-template-columns: repeat(4, 1fr); column-gap: clamp(16px, 2vw, 32px); }

.big-idx, .kw {
  display: block;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 0.9;
  margin-bottom: clamp(14px, 3vh, 32px);
}
.big-idx {
  font-size: clamp(48px, min(6vw, 11vh), 104px); font-size: round(nearest, clamp(48px, min(6vw, 11vh), 104px), 8px);
  color: var(--fg);
  transition: color 0.5s var(--ease);
}
.apart li:hover .big-idx { color: var(--red); }
.apart h3 {
  font-size: clamp(24px, 2.5vw, 40px); font-size: round(nearest, clamp(24px, 2.5vw, 40px), 4px);
  line-height: 1.1;
  margin-bottom: 12px;
}
.kw {
  font-size: clamp(32px, min(3.6vw, 7vh), 64px); font-size: round(nearest, clamp(32px, min(3.6vw, 7vh), 64px), 8px);
  color: var(--fg);
  text-transform: uppercase;
}
.impact .kw { color: var(--red); } /* "In sync" is held together by a non-breaking space */

.panel-contact .panel-head { max-width: none; }
.mega {
  font-size: clamp(72px, min(15vw, 26vh), 264px); font-size: round(nearest, clamp(72px, min(15vw, 26vh), 264px), 8px);
  font-weight: 700;
  font-stretch: 125%;
  text-transform: uppercase;
  letter-spacing: -0.045em;
  line-height: 0.84;
}
.contact-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px 48px;
  border-top: 1px solid var(--line-2);
  padding-top: clamp(18px, 3vh, 32px);
}
.contact-actions { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 24px 48px; }
.li-block { display: grid; gap: 8px; font-size: 17px; }
.li-block .label::before { display: none; }

.how-ui {
  position: absolute;
  left: var(--gut);
  right: var(--gut);
  bottom: clamp(18px, 3.4vh, 34px);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
  z-index: 5;
}
.how-count { color: var(--muted); font-size: 12px; min-width: 64px; }
.how-count b { color: var(--fg); font-weight: 500; }
.how-bars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.how-bars i {
  height: 2px;
  background: var(--line-2);
  position: relative;
  overflow: hidden;
}
.how-bars i::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--red);
  transform-origin: 0 50%;
  transform: scaleX(var(--f, 0));
}
.how-arrows { display: flex; gap: 6px; }
.arrow-btn {
  width: 44px; height: 44px;
  border: 1px solid var(--line-2);
  display: grid; place-items: center;
  font-size: 16px;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
}
.arrow-btn:hover { background: var(--fg); color: var(--ink); border-color: var(--fg); }
.arrow-btn:disabled { opacity: 0.3; pointer-events: none; }

/* ==========================================================
   MARQUEE
   ========================================================== */
.marquee {
  background: var(--red);
  color: var(--ink);
  overflow: hidden;
  border-block: 1px solid var(--red);
  position: relative;
  z-index: 2;
}
.marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  gap: clamp(20px, 2.4vw, 40px);
  padding-block: clamp(14px, 2vw, 26px);
  animation: marquee 64s linear infinite;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 700;
  font-size: clamp(24px, 4.2vw, 72px); font-size: round(nearest, clamp(24px, 4.2vw, 72px), 8px);
  letter-spacing: -0.03em;
  text-transform: uppercase;
  line-height: 1;
  white-space: nowrap;
}
.marquee-track i { font-style: normal; font-size: 0.35em; font-size: round(nearest, 0.35em, 1px); }
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee:hover .marquee-track { animation-play-state: paused; }

/* ==========================================================
   WORK — from v2 (survey mat, white cards, live night screens)
   ========================================================== */
.work {
  position: relative;
  background-color: var(--paper);
  color: var(--ink);
  --label: var(--ink-2);
}
.work .label { color: var(--ink-2); }
.work {
  padding: clamp(100px, 15vh, 170px) 0 clamp(80px, 12vh, 140px);
  background-image:
    linear-gradient(var(--ink-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--ink-line) 1px, transparent 1px),
    linear-gradient(rgba(10, 13, 28, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(10, 13, 28, 0.045) 1px, transparent 1px);
  background-size: 160px 160px, 160px 160px, 32px 32px, 32px 32px;
  background-position: -1px -1px;
}
.ruler { position: absolute; pointer-events: none; color: var(--ink-2); }
.ruler-x {
  top: 0; left: 0; right: 0; height: 22px;
  background:
    repeating-linear-gradient(90deg, rgba(10, 13, 28, 0.5) 0 1px, transparent 1px 160px) 0 0 / 100% 22px no-repeat,
    repeating-linear-gradient(90deg, rgba(10, 13, 28, 0.35) 0 1px, transparent 1px 32px) 0 0 / 100% 12px no-repeat,
    repeating-linear-gradient(90deg, rgba(10, 13, 28, 0.2) 0 1px, transparent 1px 8px) 0 0 / 100% 6px no-repeat;
  border-bottom: 1px solid var(--ink-line);
}
.ruler-y {
  top: 0; bottom: 0; left: 0; width: 22px;
  background:
    repeating-linear-gradient(rgba(10, 13, 28, 0.5) 0 1px, transparent 1px 160px) 0 0 / 22px 100% no-repeat,
    repeating-linear-gradient(rgba(10, 13, 28, 0.35) 0 1px, transparent 1px 32px) 0 0 / 12px 100% no-repeat,
    repeating-linear-gradient(rgba(10, 13, 28, 0.2) 0 1px, transparent 1px 8px) 0 0 / 6px 100% no-repeat;
  border-right: 1px solid var(--ink-line);
}
.sec-head {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end;
  gap: 18px 60px; margin-bottom: clamp(44px, 7vh, 84px);
}
.sec-head .label { grid-column: 1 / -1; }
.sec-sub { max-width: 34ch; color: var(--ink-2); font-size: 18px; line-height: 1.5; }

/* ---------- Case cards: a white card holding a live night "screen" ---------- */
.cases { display: grid; gap: clamp(18px, 2vw, 28px); }
.case { border-radius: var(--r); background: var(--card); box-shadow: 0 1px 0 rgba(10, 13, 28, 0.04), 0 30px 60px -40px rgba(10, 13, 28, 0.35); transition: transform 0.6s var(--ease), box-shadow 0.6s var(--ease); }
.case:hover { transform: translateY(-4px); box-shadow: 0 1px 0 rgba(10, 13, 28, 0.04), 0 40px 80px -40px rgba(10, 13, 28, 0.45); }
.case-link {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) minmax(0, 1.12fr);
  gap: clamp(20px, 3vw, 48px);
  padding: clamp(14px, 1.4vw, 18px);
  padding-left: clamp(22px, 2.4vw, 34px);
  align-items: stretch;
}
.case-meta { display: flex; flex-direction: column; justify-content: space-between; padding: 16px 0; color: var(--ink-2); font-size: 12px; }
.case-n { font: 300 48px/1 var(--display); letter-spacing: -0.05em; color: var(--ink); }
.case-body { display: flex; flex-direction: column; gap: 16px; padding: 16px 0; }
.case-body .label::before { display: none; }
.case-body .label { color: var(--ink-2); font-size: 12px; }
.case-title { font-size: clamp(24px, 3vw, 48px); font-size: round(nearest, clamp(24px, 3vw, 48px), 8px); line-height: 1.02; letter-spacing: -0.04em; transition: color 0.4s; }
.case:hover .case-title { color: var(--red); }
.case-desc { color: var(--ink-2); font-size: 17px; line-height: 1.55; max-width: 52ch; }
.case-result { font-size: 16px; color: var(--ink); padding: 10px 14px; border-radius: 12px; background: var(--paper); max-width: 52ch; }
.case-result .mono { color: var(--red); font-size: 12px; }
/* "Read case study" — from Denise Sharp Design (underline link, arrow nudge) */
.case-cta {
  margin-top: auto;
  align-self: flex-start;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 400;
  line-height: normal;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: inline-flex;
  gap: 10px;
  padding-top: 6px;
  border-bottom: 1px solid rgba(10, 13, 28, 0.22); /* DSD's --line-2, inked for the white card */
  padding-bottom: 6px;
  transition: color 0.3s, border-color 0.3s;
}
.case-cta i { font-style: normal; transition: transform 0.5s var(--ease); }
.case-link:hover .case-cta { color: var(--red); border-color: var(--red); }
.case-link:hover .case-cta i { transform: translateX(6px); }
.case-vis {
  position: relative; border-radius: calc(var(--r) - 8px); overflow: hidden;
  min-height: clamp(260px, 30vw, 420px);
  background:
    radial-gradient(90% 80% at 70% 100%, rgba(47, 70, 214, 0.35), transparent 70%),
    var(--night);
}
.case-vis canvas { position: absolute; inset: 0; width: 100%; height: 100%; transition: transform 1.2s var(--ease); }
.case:hover .case-vis canvas { transform: scale(1.03); }
.vis-tag {
  position: absolute; left: 14px; top: 14px; font-size: 12px; color: var(--fg);
  padding: 7px 11px; border-radius: 999px; background: rgba(238, 240, 246, 0.08); border: 1px solid var(--line);
  backdrop-filter: blur(6px);
}

/* ==========================================================
/* ==========================================================
   ABOUT (light)
   ========================================================== */
.about {
  background: var(--paper);
  color: var(--ink);
  padding-block: clamp(96px, 12vw, 180px);
  position: relative;
}
.about .label { color: var(--ink-2); }
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(40px, 6vw, 120px);
}
.about-left { display: flex; flex-direction: column; gap: 24px; }
.about-left .h1, .words-left .h1 { letter-spacing: -0.03em; font-size: clamp(40px, 4.4vw, 80px); font-size: round(nearest, clamp(40px, 4.4vw, 80px), 8px); }
.portrait {
  position: relative;
  margin-top: clamp(16px, 3vw, 40px);
  max-width: 440px;
  aspect-ratio: 4 / 5;
  background: var(--paper-2);
  padding: 10px;
}
.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) contrast(1.06);
  transition: filter 0.8s var(--ease);
}
.portrait:hover img { filter: grayscale(0) contrast(1); }
.portrait .frame-corner { border-color: var(--ink); opacity: 0.8; width: 18px; height: 18px; }
.portrait figcaption {
  position: absolute;
  left: 10px; right: 10px; bottom: -28px;
  display: flex;
  justify-content: space-between;
  color: var(--ink-2);
  font-size: 12px;
}
.about-copy {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-top: clamp(8px, 4vw, 70px);
  color: var(--ink-2);
  font-size: clamp(16px, 1.15vw, 18px); font-size: round(nearest, clamp(16px, 1.15vw, 18px), 1px);
  line-height: 1.65;
}
.about-lead {
  font-family: var(--display);
  font-stretch: 105%;
  font-size: clamp(22px, 1.9vw, 30px); font-size: round(nearest, clamp(22px, 1.9vw, 30px), 1px);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 8px;
}

.timeline {
  position: relative;
  margin-top: clamp(40px, 5vw, 80px);
  --p: 0;
}
.tl-rail {
  position: relative;
  height: 1px;
  background: var(--ink-line);
  margin-top: 36px;
}
.tl-fill {
  position: absolute;
  inset: 0;
  background: var(--red);
  transform-origin: 0 50%;
  transform: scaleX(var(--p));
}
.tl-list {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
}
.tl-list li {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 32px;
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.35;
  transition: color 0.5s;
}
.tl-node {
  position: absolute;
  top: -5px;
  left: 0;
  width: 9px; height: 9px;
  background: var(--paper);
  border: 1px solid var(--ink-2);
  transform: rotate(45deg);
  transition: background 0.4s, border-color 0.4s, transform 0.6s var(--ease);
}
.tl-list li.on .tl-node { background: var(--red); border-color: var(--red); transform: rotate(225deg) scale(1.2); }
.tl-year {
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 700;
  font-size: clamp(32px, 3vw, 48px); font-size: round(nearest, clamp(32px, 3vw, 48px), 8px);
  letter-spacing: -0.04em;
  line-height: 1;
  color: rgba(10, 13, 28, 0.22);
  margin-bottom: 12px;
  transition: color 0.6s;
}
.tl-list li.on .tl-year { color: var(--ink); }
.tl-list strong { color: var(--ink); font-weight: 600; font-size: 16px; }

.skills {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: clamp(80px, 9vw, 140px);
  border-top: 1px solid var(--ink);
}
.skills li {
  padding: 26px clamp(14px, 2vw, 28px) 30px;
  border-right: 1px solid var(--ink-line);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: background 0.5s var(--ease), color 0.5s;
}
.skills li:first-child { padding-left: 0; }
.skills li:last-child { border-right: 0; }
.skills .mono { color: var(--red-ink); font-size: 12px; }
.skills h3 {
  font-family: var(--display);
  font-stretch: 112%;
  font-size: clamp(20px, 1.7vw, 26px); font-size: round(nearest, clamp(20px, 1.7vw, 26px), 1px);
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-top: 28px;
}
.skills p { color: var(--ink-2); font-size: 15px; line-height: 1.5; transition: color 0.5s; }

/* ==========================================================
   KIND WORDS
   ========================================================== */
.words { padding-block: clamp(96px, 12vw, 180px); }
.words-grid {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  gap: clamp(40px, 6vw, 120px);
}
.words-left { display: flex; flex-direction: column; gap: 24px; }
.q-tabs { display: grid; margin-top: clamp(16px, 3vw, 40px); border-top: 1px solid var(--line-2); }
.q-tab {
  position: relative;
  text-align: left;
  display: grid;
  gap: 2px;
  padding: 18px 0 20px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  transition: color 0.4s;
}
.q-tab:hover, .q-tab.is-active { color: var(--fg); }
.q-name {
  font-family: var(--display);
  font-stretch: 110%;
  font-weight: 600;
  font-size: 19px;
  letter-spacing: -0.01em;
}
.q-role { font-size: 13px; color: var(--muted); }
.q-bar {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 1px;
  overflow: hidden;
}
.q-bar b {
  display: block;
  height: 100%;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: 0 50%;
}
.q-tab.is-active .q-bar b { animation: qbar var(--qdur, 10s) linear forwards; }
.words:hover .q-tab.is-active .q-bar b,
.words.is-paused .q-tab.is-active .q-bar b { animation-play-state: paused; }
@keyframes qbar { to { transform: scaleX(1); } }

.q-stage {
  position: relative;
  display: grid;
  align-content: center;
  padding-top: clamp(40px, 6vw, 100px);
}
.q-mark {
  position: absolute;
  top: -0.1em;
  left: -0.06em;
  font-family: var(--display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: clamp(160px, 18vw, 304px); font-size: round(nearest, clamp(160px, 18vw, 304px), 8px);
  line-height: 1;
  color: var(--red);
  opacity: 0.9;
  pointer-events: none;
}
.q {
  grid-area: 1 / 1;
  opacity: 0;
  visibility: hidden;
  transform: translateY(18px);
  filter: blur(6px);
  transition: opacity 0.7s var(--ease), transform 0.9s var(--ease), filter 0.7s var(--ease), visibility 0s 0.7s;
}
.q.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  filter: none;
  transition-delay: 0.15s, 0.15s, 0.15s, 0s;
}
.q blockquote {
  font-family: var(--display);
  font-stretch: 104%;
  font-weight: 450;
  font-size: clamp(21px, 2.05vw, 34px); font-size: round(nearest, clamp(21px, 2.05vw, 34px), 1px);
  line-height: 1.28;
  letter-spacing: -0.015em;
  position: relative;
  z-index: 1;
}
.q figcaption {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  align-items: baseline;
  padding-top: 18px;
  border-top: 1px solid var(--line-2);
}
.q figcaption strong { font-weight: 600; }
.q figcaption span { color: var(--muted); font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }

/* ==========================================================
   CTA
   ========================================================== */
.cta {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-top: 1px solid var(--line);
  background: radial-gradient(70% 60% at 50% 100%, #12161a 0%, var(--bg) 70%);
}
.cta-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.cta-inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: clamp(28px, 4vw, 48px);
  padding-block: 120px 34vh;
}
.cta-title {
  font-size: clamp(40px, 7.4vw, 120px); font-size: round(nearest, clamp(40px, 7.4vw, 120px), 8px);
  font-weight: 700;
  font-stretch: 122%;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 0.9;
}
.cta-alt { color: var(--fg-2); display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; justify-content: center; }
.cta-alt .ulink { color: var(--fg); }

/* ==========================================================
   FOOTER
   ========================================================== */
.footer {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding-top: 28px;
  overflow: hidden;
}
.foot-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  font-size: 14px;
}
.foot-name { font-family: var(--display); font-stretch: 118%; font-weight: 600; text-transform: uppercase; font-size: 13px; }
.foot-copy { color: var(--muted); font-size: 12px; }
.foot-links { display: flex; gap: 22px; justify-self: end; }
.wordmark {
  margin-top: clamp(24px, 4vw, 56px);
  font-weight: 800;
  font-stretch: 125%;
  text-transform: uppercase;
  letter-spacing: -0.045em;
  line-height: 0.8;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(238, 240, 246, 0.3);
  font-size: 10vw; font-size: round(nearest, 10vw, 8px);
  padding-bottom: clamp(16px, 2vw, 32px);
  user-select: none;
}
.wordmark span { display: inline-block; transition: color 0.8s var(--ease); }
.footer:hover .wordmark span { color: var(--red); -webkit-text-stroke-color: var(--red); }

/* ==========================================================
   MOTION: reveals
   ========================================================== */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease), transform 1.1s var(--ease);
  transition-delay: var(--d, 0s);
}
.js [data-reveal].in { opacity: 1; transform: none; }

.w {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
}
.w > span {
  display: inline-block;
  transform: translateY(108%);
  transition: transform 1.15s var(--ease);
  transition-delay: calc(var(--i, 0) * 60ms + var(--d, 0s));
}
[data-split].in .w > span { transform: none; }
.hero-title .w { padding-bottom: 0.04em; }

.js .cells li, .js .tl-list li {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.9s var(--ease), transform 1s var(--ease), color 0.5s;
  transition-delay: calc(var(--k, 0) * 80ms);
}
.js .panel.in .cells li, .js .timeline.in .tl-list li { opacity: 1; transform: none; }

/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 1100px) {
  .case-link { grid-template-columns: 60px minmax(0, 1fr); }
  .case-vis { grid-column: 1 / -1; }
  .cells-4 { grid-template-columns: repeat(2, 1fr); }
  .skills { grid-template-columns: repeat(2, 1fr); }
  .skills li:nth-child(2) { border-right: 0; }
  .skills li:nth-child(3) { padding-left: 0; }
  .skills li { border-bottom: 1px solid var(--ink-line); }
}

@media (max-width: 900px) {
  :root { --nav-h: 60px; }
  body { font-size: 16px; }
  .nav-clock { display: none; }

  .hero-meta { padding-inline: 0; }
  .hero-loc .coords { display: none; }
  .hero > .frame-corner { display: none; }
  .scroll-cue { display: none; }
  .hero-title { font-size: clamp(48px, 14.4vw, 120px); font-size: round(nearest, clamp(48px, 14.4vw, 120px), 8px); }

  .hero-cta { gap: 0; }

  /* Panels become a native swipe carousel */
  .how { height: auto; }
  .how-sticky { position: relative; height: auto; overflow: visible; background: var(--bg); }
  .how-track {
    width: 100%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    transform: none !important;
    align-items: stretch;
  }
  .how-track::-webkit-scrollbar { display: none; }
  .panel {
    width: 100%;
    height: auto;
    min-height: 0;
    scroll-snap-align: start;
    padding: 72px var(--gut) 112px;
    justify-content: flex-start;
  }
  .panel-intro, .panel-contact { justify-content: center; }
  .panel-intro .panel-head { margin-top: 0; }
  .panel-num { font-size: 152px; top: 24px; transform: none; }
  .cells-6, .cells-4 { grid-template-columns: 1fr 1fr; column-gap: 16px; }
  .cells li { padding-right: 0; }
  .cells h3 { font-size: 16px; }
  .cells p { max-width: none; font-size: 14px; }
  .cell-idx { margin-bottom: 6px; }
  .big-idx { font-size: 48px; margin-bottom: 10px; }
  .apart h3 { font-size: 24px; margin-bottom: 8px; }
  .kw { font-size: clamp(22px, 7vw, 34px); font-size: round(nearest, clamp(22px, 7vw, 34px), 1px); margin-bottom: 10px; }
  .cells li { min-width: 0; }
  .how-ui { bottom: 32px; gap: 16px; }
  .mega { font-size: clamp(72px, 26vw, 160px); font-size: round(nearest, clamp(72px, 26vw, 160px), 8px); }
  .js .cells li { opacity: 1; transform: none; }

  .ruler { display: none; }
  .case-link { grid-template-columns: 1fr; gap: 14px; padding: 14px; }
  .case-meta { flex-direction: row; align-items: baseline; justify-content: space-between; padding: 8px 6px 0; }
  .case-n { font-size: 34px; }
  .case-body { padding: 0 6px 8px; }
  .case-vis { min-height: 240px; grid-row: 2; }
  .sec-head { grid-template-columns: 1fr; }

  .about-grid, .words-grid { grid-template-columns: 1fr; }
  .about-copy { padding-top: 0; }
  .portrait { max-width: 360px; }

  .timeline { --axis: 1; }
  .tl-rail {
    position: absolute;
    left: 4px; top: 64px; bottom: 0;
    width: 1px; height: auto;
    margin: 0;
  }
  .tl-fill { transform-origin: 50% 0; transform: scaleY(var(--p)); }
  .tl-list { grid-template-columns: 1fr; gap: 0; margin-top: 28px; }
  .tl-list li { padding: 0 0 30px 34px; }
  .tl-node { top: 6px; left: 0; }
  .tl-year { margin-bottom: 4px; }

  .skills { grid-template-columns: 1fr; }
  .skills li, .skills li:nth-child(3) { padding-left: 0; border-right: 0; }

  .words-grid { gap: 24px; }
  .words-left { display: contents; }
  .q-stage { padding-top: 70px; order: 3; }
  .q-tabs { order: 4; margin-top: 24px; }
  .q-mark { font-size: 152px; }

  .foot-row { grid-template-columns: 1fr; justify-items: start; }
  .foot-links { justify-self: start; }
}

@media (max-width: 520px) {
  .nav-right { gap: 14px; }
  .brand { font-size: 13px; gap: 8px; }
  .btn-sm { padding: 0 10px; font-size: 12px; }
  .nav-link { font-size: 12px; }
}

@media (max-width: 400px) {
  .brand { font-size: 12px; gap: 7px; letter-spacing: 0; }
  .brand-mark { width: 10px; height: 10px; }
  .nav-right { gap: 12px; }
  .btn-sm { padding: 0 9px; }
}

/* ==========================================================
   REDUCED MOTION
   ========================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0s !important;
  }
  .marquee-track { animation: none; }
}

/* ==========================================================
   ALTIMETER — fixed descent gauge (v2), squared to match the system
   ========================================================== */
.alt {
  position: fixed;
  right: 10px;
  top: 50%;
  z-index: 40;
  transform: translate(10px, -50%);
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 14px 8px 12px;
  background: rgba(4, 5, 13, 0.74);
  border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  color: var(--fg);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s, transform 0.6s var(--ease);
}
.alt::before, .alt::after {
  content: ""; position: absolute; width: 7px; height: 7px; border: 0 solid var(--red);
}
.alt::before { top: -1px; left: -1px; border-top-width: 1px; border-left-width: 1px; }
.alt::after { bottom: -1px; right: -1px; border-bottom-width: 1px; border-right-width: 1px; }
.alt.on { opacity: 1; transform: translate(0, -50%); }
.alt-k { font-size: 12px; color: var(--muted); letter-spacing: 0.08em; }
.alt-rail { position: relative; width: 9px; height: 150px; background: repeating-linear-gradient(var(--line-2) 0 1px, transparent 1px 10px) center / 9px 100% no-repeat; }
.alt-rail::before { content: ""; position: absolute; left: 4px; top: 0; bottom: 0; width: 1px; background: var(--line); }
.alt-dot {
  position: absolute; left: 0; top: 0; width: 9px; height: 9px; margin-top: -4.5px;
  background: var(--red);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0 60%, 40% 60%, 40% 40%, 0 40%);
  transform: translateY(calc(var(--ap, 0) * 150px));
}
.alt b { font-size: 12px; font-weight: 500; writing-mode: vertical-rl; transform: rotate(180deg); letter-spacing: 0.08em; min-height: 58px; text-align: left; }
@media (max-width: 1100px) { .alt { display: none; } }

/* ==========================================================
   BLUE SKIES — background colours from v2 (Contact)
   ========================================================== */
/* Contact: dusk — atmosphere blue fading into night */
/* Contact: starts at the testimonials' night, eases up into dusk blue, settles back to night */
.cta {
  border-top: 0;
  background: linear-gradient(180deg,
    var(--bg) 0%,
    #070a1c 10%,
    #0d1335 22%,
    #151d55 36%,
    #1a2468 46%,
    #141c52 58%,
    #0b0f2c 74%,
    var(--bg) 100%);
}

/* ==========================================================
   Red markers on the homepage: v2's label dot replaces the
   short red lines (labels + service cards). Case pages unchanged.
   ========================================================== */
.home .label { gap: 12px; }
.home .label::before {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 4px rgba(255, 59, 46, 0.16);
  margin-left: 4px;
}

/* About: photo first, then label + title */
.about-left .portrait { margin-top: 0; margin-bottom: clamp(12px, 2vw, 28px); }
.about-left > .label { margin-bottom: clamp(4px, 1vw, 12px); }


/* ==========================================================
   FOOTER — responsive
   ========================================================== */
.wordmark {
  font-weight: 500;
  letter-spacing: -0.015em;      /* outlined letters no longer cross each other */
  line-height: 0.9;
  -webkit-text-stroke-width: 1px;
}
.foot-row { row-gap: 14px; }
.foot-links { flex-wrap: wrap; row-gap: 10px; }
@media (max-width: 900px) {
  /* tablet: name + links on one line, copyright under them */
  .foot-row { grid-template-columns: minmax(0, 1fr) auto; justify-items: stretch; align-items: center; }
  .foot-name { grid-column: 1; grid-row: 1; }
  .foot-links { grid-column: 2; grid-row: 1; justify-self: end; }
  .foot-copy { grid-column: 1 / -1; grid-row: 2; }
}
@media (max-width: 520px) {
  /* phone: clean single column */
  .foot-row { grid-template-columns: minmax(0, 1fr); padding-bottom: 6px; }
  .foot-name, .foot-links, .foot-copy { grid-column: 1; grid-row: auto; justify-self: start; }
  .foot-links { gap: 10px 22px; }
  .wordmark { -webkit-text-stroke-width: 0.75px; margin-top: 20px; }
}
/* wordmark: outlined lettering. The outline is a thin ring traced around each letter's silhouette
   (text-shadow under a background-coloured fill), so the variable font's overlapping contours never show. */
.wordmark {
  --wm-line: #4a4b55;
  color: var(--bg);
  -webkit-text-stroke: 0 transparent;
  letter-spacing: 0;
  text-shadow:
    1px 0 0 var(--wm-line), -1px 0 0 var(--wm-line), 0 1px 0 var(--wm-line), 0 -1px 0 var(--wm-line),
    0.7px 0.7px 0 var(--wm-line), -0.7px 0.7px 0 var(--wm-line), 0.7px -0.7px 0 var(--wm-line), -0.7px -0.7px 0 var(--wm-line);
}
.footer:hover .wordmark span { color: var(--red); -webkit-text-stroke-color: transparent; text-shadow: none; }

/* ==========================================================
   WORK — case-body spacing rhythm
   label → 14 → title → 18 → description → 18 → result … ≥28 → CTA (bottom)
   ========================================================== */
.case-body { gap: 0; padding: 18px 0 16px; }
.case-body > .label { margin-bottom: 30px; }
.case-body > .case-title { margin-bottom: 12px; }
.case-body > .case-desc + .case-result { margin-top: 18px; }
.case-body > :nth-last-child(2) { margin-bottom: 28px; }
.case-body > .case-cta { margin-top: auto; }
.case-meta { padding: 18px 0 16px; }
@media (max-width: 900px) {
  .case-body { padding: 4px 6px 10px; }
  .case-body > .label { margin-bottom: 22px; }
  .case-body > .case-title { margin-bottom: 10px; }
  .case-body > .case-desc + .case-result { margin-top: 14px; }
  .case-body > :nth-last-child(2) { margin-bottom: 22px; }
  .case-meta { padding: 8px 6px 0; }
}

/* ==========================================================
   Label marker: the red circle replaces the short red line
   everywhere (home and case studies)
   ========================================================== */
.label { gap: 12px; }
.label::before {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 4px rgba(255, 59, 46, 0.16);
  margin-left: 4px;
}

/* case card year: keep ranges like "2019 & 2026" on one line */
.case-meta span { white-space: nowrap; }


/* case card tags: break lines only between tags */
.case-body > .label { display: block; }
.case-body .label .t { white-space: nowrap; }

/* About heading: fixed size */
.about .h1 { font-size: min(56px, 12.5vw); font-size: round(nearest, min(56px, 12.5vw), 8px); }


@media (max-width: 900px) {
  /* scale down just enough to stay on one line on narrow screens */
  .words-left .h1 { font-size: min(40px, calc((100vw - 40px) / 11.4)); font-size: round(down, min(40px, calc((100vw - 40px) / 11.4)), 1px); }
}

/* ==========================================================
   NAV — mobile menu (hamburger) up to 760px.
   "Denise Ventura" always stays visible in the bar.
   ========================================================== */
.nav-toggle { display: none; }
@media (max-width: 760px) {
  .nav { gap: 16px; }
  .brand { font-size: 13px; gap: 8px; }
  .brand-mark { width: 12px; height: 12px; }
  .nav-toggle {
    display: inline-flex; align-items: center; gap: 10px;
    min-height: 44px; padding: 0 4px 0 12px; margin-right: -4px;
    font: 500 12px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--fg); background: none; border: 0; cursor: pointer;
  }
  .nav-toggle-bars { position: relative; width: 20px; height: 12px; display: inline-block; }
  .nav-toggle-bars i {
    position: absolute; left: 0; right: 0; height: 2px; background: currentColor;
    transition: transform 0.3s var(--ease), top 0.3s var(--ease);
  }
  .nav-toggle-bars i:first-child { top: 1px; }
  .nav-toggle-bars i:last-child { top: 9px; }
  .nav.menu-open .nav-toggle-bars i:first-child { top: 5px; transform: rotate(45deg); }
  .nav.menu-open .nav-toggle-bars i:last-child { top: 5px; transform: rotate(-45deg); }

  /* the links become a panel under the bar */
  .nav-right {
    position: absolute; top: 100%; left: 0; right: 0;
    display: flex; flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px var(--gut) 24px;
    background: var(--bg);
    border-bottom: 1px solid var(--line-2);
    box-shadow: 0 24px 40px -16px rgba(0, 0, 0, 0.7);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0s linear 0.25s;
  }
  .nav.menu-open .nav-right {
    opacity: 1; visibility: visible; transform: none;
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0s;
  }
  .nav.menu-open { background: var(--bg); border-bottom-color: var(--line); }
  .nav-right .nav-clock { display: none; }
  .nav-right .nav-link {
    display: flex; align-items: center; min-height: 56px; padding: 0;
    font-size: 14px; letter-spacing: 0.08em; color: var(--fg);
    border-bottom: 1px solid var(--line);
  }
  .nav-right .nav-link::before, .nav-right .nav-link::after { display: none; }
  .nav-right .btn { margin-top: 24px; justify-content: center; min-height: 48px; width: 100%; font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .nav-right, .nav-toggle-bars i { transition: none !important; }
}

/* ==========================================================
   RESPONSIVE FIXES
   ========================================================== */
/* Labels: the dot sits on the first line when a label wraps; the "live" dot lines up with the others */
.label { align-items: flex-start; }
.label::before { margin-top: calc((1.5em - 7px) / 2); }
.label { line-height: 1.5; }
.hero-loc { gap: 12px; }
.hero-loc .live { flex: none; margin-left: 4px; margin-top: calc((1.5em - 7px) / 2); }

/* Local time sits in the bar at every size: left of the links on desktop, left of the Menu button on mobile */
.nav > .nav-clock { display: inline-block; margin-left: auto; margin-right: clamp(14px, 2.4vw, 36px); white-space: nowrap; }
@media (max-width: 760px) {
  .nav > .nav-clock { margin-right: 0; }
}
/* Narrow phones: drop the seconds and show the menu icon alone (the button keeps its "Menu" name for screen readers) */
@media (max-width: 410px) {
  .nav { gap: 12px; }
  .nav-clock .sec { display: none; }
  .nav-toggle { padding-left: 8px; }
  .nav-toggle-label { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* nav name stays on one line */
.brand { white-space: nowrap; }

/* ==========================================================
   LINE BREAKS — even headings, no single stranded words
   ========================================================== */
h1, h2, h3, h4, .h1, .h2, .statement, .c-h2, .c-h3, .c-title, .case-title, blockquote, .label, .kw {
  text-wrap: balance;
}
p, li, dd, figcaption, .lede, .c-cap {
  text-wrap: pretty;
}
.hero-title, .wordmark { text-wrap: nowrap; }
.cta-title { text-wrap: wrap; }
.nw { white-space: nowrap; } /* keeps two words together */

/* What sets me apart: smallest phones */
@media (max-width: 380px) {
  .apart h3 { font-size: 20px; }
}

/* side margins: smallest phones, so the nav fits */
@media (max-width: 339px) {
  :root { --gut: 20px; }
}

/* ==========================================================
   WCAG 2.2 AA review
   ========================================================== */
/* Animated headings: the word mask was cropping descenders (g, p, y, commas) and letter edges.
   Give each word mask room below and at the sides without changing the layout. */
.w, .hero-title .w { padding: 0.02em 0.08em 0.22em; margin: -0.02em -0.08em -0.22em; }
/* hero title on phones and tablets: never wider than the space between the side margins ("DESIGNER" ≈ 6.4 × font size) */
@media (max-width: 1100px) {
  .hero-title { font-size: min(14.4vw, (100vw - 2 * var(--gut)) / 6.6, 120px); font-size: round(down, min(14.4vw, (100vw - 2 * var(--gut)) / 6.6, 120px), 8px); }
}
.w > span { transform: translateY(140%); }
[data-split].in .w > span { transform: none; }
/* 1.4.12 Text spacing: if a reader enlarges letter or word spacing, very long words break instead of being cut off */
h1, h2, h3, .c-title, .hero-title, .cta-title, .statement, .c-h2, .mega { overflow-wrap: break-word; }
.w { max-width: calc(100% + 0.16em); }
.w, .w > span { overflow-wrap: anywhere; }
.impact .kw { overflow-wrap: normal; word-break: keep-all; } /* single words never split */
.w > span { max-width: 100%; }
/* How panels: if enlarged text spacing makes a panel's content taller than the screen, it scrolls instead of being cut off */
.panel { overflow: hidden auto; scrollbar-width: none; }
.panel::-webkit-scrollbar { display: none; }
.hero-title, .hero-title .ln { text-wrap: wrap; white-space: normal; }
/* How panels on short laptop screens: tighten the vertical rhythm so content never runs into the counter and arrows */
@media (min-width: 901px) and (max-height: 800px) {
  .panel { padding-top: calc(var(--nav-h) + 16px); gap: 20px; }
}
@media (min-width: 901px) and (max-height: 680px) {
  .panel-head { gap: 32px; }
  .panel { padding-bottom: 96px; }
}
@media (min-width: 901px) and (max-height: 620px) {
  .panel-head { gap: 24px; }
  .panel { gap: 16px; padding-bottom: 88px; }
  .apart h3 { font-size: 24px; }
  .kw { font-size: 32px; margin-bottom: 8px; }
  .cell-idx { margin-bottom: 8px; }
}
/* CTA title: the longest word ("SOMETHING") always fits between the side margins */
.cta-title { font-size: min(clamp(40px, 7.4vw, 120px), (100vw - 2 * var(--gut)) / 7.6); font-size: round(down, min(clamp(40px, 7.4vw, 120px), (100vw - 2 * var(--gut)) / 7.6), 8px); }
/* 2.5.8 Target size: small text links get a 24px-tall hit area without moving anything */
.brand, .nav-link { padding-block: 4px; margin-block: -4px; }
.nav-link { display: inline-block; }
.ulink { padding-top: 2px; margin-top: -2px; }
/* Alignment on wide screens (over 1680px + margins): the nav, hero frame, How panels and counters line up
   with the page content column instead of sitting closer to the screen edge */
.nav { padding-inline: max(var(--gut), calc((100% - 1680px) / 2 + var(--gut))); }
.hero > .frame-corner.tl, .hero > .frame-corner.bl { left: max(var(--gut), calc((100% - 1680px) / 2 + var(--gut))); }
.hero > .frame-corner.tr, .hero > .frame-corner.br { right: max(var(--gut), calc((100% - 1680px) / 2 + var(--gut))); }
.how-ui { left: max(var(--gut), calc((100% - 1680px) / 2 + var(--gut))); right: max(var(--gut), calc((100% - 1680px) / 2 + var(--gut))); }
@media (min-width: 901px) {
  .panel { padding-inline: max(var(--gut), calc((var(--vw, 100vw) - 1680px) / 2 + var(--gut))); }
  .panel-num { right: calc(max(var(--gut), calc((var(--vw, 100vw) - 1680px) / 2 + var(--gut))) - 0.06em); }
}
/* 2.2.2 Pause: the rotating testimonials also pause while a keyboard user is on them (they already pause on hover) */
.words:focus-within .q-tab.is-active .q-bar b { animation-play-state: paused; }
