/* ==========================================================================
   Matmon — editorial brand system
   Brand constants: navy #0D5270 · cyan #2CA6DE · gold #F6B819 · grey #3B4951
   ========================================================================== */

:root {
  /* Type scale */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 5rem);
  --text-hero: clamp(2.75rem, 0.5rem + 6.2vw, 7rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Radius / motion / shadow */
  --radius-sm: 0.25rem;
  --radius-md: 0.375rem;
  --radius-lg: 0.5rem;
  --radius-full: 9999px;
  --transition-interactive: 200ms cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* Content widths */
  --content-narrow: 680px;
  --content-default: 1000px;
  --content-wide: 1280px;
  --gutter: clamp(1.25rem, 5vw, 5rem);

  /* Fonts */
  --font-display: 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
}

:root,
[data-theme='light'] {
  --color-bg: #f7f6f3;
  --color-surface: #fdfcfa;
  --color-surface-2: #f2f0ec;
  --color-surface-offset: #eceae5;
  --color-ink-block: #0b1c28;
  --color-divider: #dedbd4;
  --color-border: #cdc9c1;

  --color-text: #131f28;
  --color-text-muted: #5c6670;
  --color-text-faint: #9aa1a8;
  --color-text-inverse: #f7f6f3;

  /* Brand palette — Matmon Style Guide */
  --color-primary: #0d5270; /* Dark Blue */
  --color-primary-hover: #0a4058;
  --color-primary-active: #072f42;
  --color-cyan: #2ca6de; /* Accent Cyan */
  --color-cyan-deep: #1c85b8;
  --color-grey: #3b4951; /* Accent Grey */
  --color-gold: #b98204;
  --color-gold-bright: #f6b819;

  --shadow-sm: 0 1px 2px rgb(11 28 40 / 0.06);
  --shadow-md: 0 6px 20px rgb(11 28 40 / 0.09);
  --shadow-lg: 0 18px 48px rgb(11 28 40 / 0.14);
}


/* ---------- base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  min-height: 100dvh;
  line-height: 1.65;
  font-family: var(--font-body);
  font-weight: 500; /* Montserrat Medium — style guide body weight */
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
  overflow-x: hidden;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}
ul[role='list'],
ol[role='list'] {
  list-style: none;
}
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
  background: none;
  border: none;
}

h1,
h2,
h3,
h4 {
  text-wrap: balance;
  line-height: 1.1;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
}
p,
li,
figcaption {
  text-wrap: pretty;
}
p {
  max-width: 68ch;
}

a {
  color: inherit;
  text-decoration: none;
}
a,
button,
input,
textarea,
select {
  transition:
    color var(--transition-interactive),
    background var(--transition-interactive),
    border-color var(--transition-interactive),
    box-shadow var(--transition-interactive),
    opacity var(--transition-interactive);
}

::selection {
  background: color-mix(in oklab, var(--color-gold-bright) 35%, transparent);
  color: var(--color-text);
}
:focus-visible {
  outline: 2px solid var(--color-cyan);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: var(--space-2);
  z-index: 200;
  padding: var(--space-2) var(--space-4);
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-sm);
  transform: translateY(-200%);
}
.skip-link:focus-visible {
  transform: translateY(0);
}

/* ---------- layout primitives ---------- */
.shell {
  width: 100%;
  max-width: var(--content-wide);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.shell--default {
  max-width: var(--content-default);
}
.shell--narrow {
  max-width: var(--content-narrow);
}

section {
  position: relative;
}
.band {
  padding-block: clamp(var(--space-16), 9vw, var(--space-32));
}
.band--tight {
  padding-block: clamp(var(--space-12), 6vw, var(--space-20));
}
.band--rule {
  border-top: 1px solid var(--color-divider);
}
.band--surface {
  background: var(--color-surface-2);
}
.band--ink {
  background: var(--color-ink-block);
  color: #e6ebef;
}
.band--ink h2,
.band--ink h3 {
  color: #fff;
}
.band--ink .eyebrow {
  color: var(--color-gold-bright);
}
.band--ink p {
  color: #b7c2ca;
}

/* editorial section head: number + vertical label + title */
.sec-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-6);
  margin-bottom: clamp(var(--space-8), 4vw, var(--space-16));
}
@media (min-width: 900px) {
  .sec-head {
    grid-template-columns: 14rem minmax(0, 1fr);
    gap: var(--space-10);
    align-items: start;
  }
}
.sec-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-gold);
  padding-top: 0.4em;
  border-top: 2px solid var(--color-gold);
  display: inline-block;
}
.sec-title {
  font-size: var(--text-xl);
  max-width: 24ch;
}
.sec-head p {
  margin-top: var(--space-4);
  color: var(--color-text-muted);
  font-size: var(--text-base);
}

.eyebrow {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.lede {
  font-size: var(--text-lg);
  line-height: 1.5;
  color: var(--color-text);
  max-width: 46ch;
}

.side-label {
  display: none;
}
@media (min-width: 1200px) {
  .side-label {
    display: block;
    position: absolute;
    left: calc(var(--gutter) * -1 + 1.1rem);
    top: 0;
    writing-mode: vertical-rl;
    font-family: var(--font-display);
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--color-text-faint);
  }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.85em 1.5em;
  border-radius: var(--radius-full);
  border: 1.5px solid transparent;
}
.btn svg {
  width: 1em;
  height: 1em;
  flex: none;
}
.btn--primary {
  background: var(--color-primary);
  color: #fff;
}
.btn--primary:hover {
  background: var(--color-primary-hover);
  transform: translateY(-1px);
}
.btn--ghost {
  border-color: var(--color-border);
  color: var(--color-text);
}
.btn--ghost:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.btn--gold {
  background: var(--color-gold-bright);
  color: #1a1204;
}
.btn--gold:hover {
  background: var(--color-gold);
  color: #fff;
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-8);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--color-primary);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
}
.link-arrow svg {
  width: 0.95em;
  height: 0.95em;
  transition: transform var(--transition-interactive);
}
.link-arrow:hover {
  border-color: currentColor;
}
.link-arrow:hover svg {
  transform: translateX(4px);
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--color-bg) 88%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition:
    border-color var(--transition-interactive),
    background var(--transition-interactive);
}
.site-header.is-scrolled {
  border-bottom-color: var(--color-divider);
}
.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  min-height: 4.75rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--color-text);
  flex: none;
}
.brand__logo {
  display: block;
  height: 1.5rem;
  width: auto;
}
@media (min-width: 768px) {
  .brand__logo {
    height: 1.75rem;
  }
}

.nav {
  margin-left: auto;
  display: none;
}
@media (min-width: 1024px) {
  .nav {
    display: flex;
    align-items: center;
    gap: clamp(var(--space-4), 1.8vw, var(--space-8));
  }
}
.nav a {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  padding-block: 0.35em;
  border-bottom: 2px solid transparent;
}
.nav a:hover {
  color: var(--color-text);
}
.nav a[aria-current='page'] {
  color: var(--color-text);
  border-bottom-color: var(--color-gold-bright);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-left: auto;
}
@media (min-width: 1024px) {
  .header__actions {
    margin-left: 0;
  }
}
.icon-btn {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
}
.icon-btn:hover {
  color: var(--color-text);
  border-color: var(--color-text-muted);
}
.header__cta {
  display: none;
}
@media (min-width: 640px) {
  .header__cta {
    display: inline-flex;
  }
}
.nav-toggle {
  display: grid;
}
@media (min-width: 1024px) {
  .nav-toggle {
    display: none;
  }
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--color-divider);
  background: var(--color-surface);
  padding: var(--space-4) 0 var(--space-8);
}
.mobile-nav.is-open {
  display: block;
}
.mobile-nav ul {
  list-style: none;
  display: grid;
  gap: var(--space-1);
}
.mobile-nav a {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-base);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--color-divider);
}
.mobile-nav .mobile-nav__cta {
  margin-top: var(--space-5);
  border-bottom: 0;
  text-align: center;
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding-block: clamp(var(--space-16), 10vw, var(--space-32)) clamp(var(--space-12), 7vw, var(--space-24));
  overflow: hidden;
}
.hero__grid {
  display: grid;
  gap: var(--space-10);
  align-items: center;
}
@media (min-width: 1024px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: clamp(var(--space-10), 5vw, var(--space-20));
  }
}
.hero__rule {
  width: 4.5rem;
  height: 2px;
  background: var(--color-gold-bright);
  margin-bottom: var(--space-6);
}
.hero h1 {
  font-size: var(--text-hero);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 0.94;
  text-transform: uppercase;
}
.hero h1 .dot {
  color: var(--color-gold-bright);
}
.hero h1 .thin {
  display: block;
  font-weight: 300;
  letter-spacing: -0.02em;
}
.hero__copy {
  margin-top: var(--space-6);
  font-size: var(--text-lg);
  line-height: 1.5;
  color: var(--color-text-muted);
  max-width: 44ch;
}
.hero__meta {
  margin-top: clamp(var(--space-10), 5vw, var(--space-16));
  display: grid;
  gap: var(--space-6);
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  border-top: 1px solid var(--color-divider);
  padding-top: var(--space-6);
}
.hero__meta div span {
  display: block;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 800;
  color: var(--color-text);
}
.hero__meta div small {
  display: block;
  margin-top: 0.15em;
  font-size: var(--text-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text-faint);
}
.hero__mark {
  justify-self: center;
  width: min(100%, 26rem);
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.75rem);
  justify-items: center;
}
.hero__mark-rule {
  display: block;
  width: 100%;
  height: 1px;
  background: var(--color-border);
}
.hero__knot {
  width: min(62%, 14rem);
  height: auto;
  animation: knot-in 1.1s var(--ease-out) both;
}
@keyframes knot-in {
  from {
    opacity: 0;
    transform: scale(0.94) rotate(-6deg);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .hero__knot {
    animation: none;
  }
}

/* ---------- knot / draw animation ---------- */
.knot path,
.knot circle,
.knot rect {
  vector-effect: non-scaling-stroke;
}
.knot--draw path {
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: draw 2.6s var(--ease-out) forwards;
}
@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .knot--draw path {
    animation: none;
    stroke-dashoffset: 0;
  }
}

/* ---------- reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 700ms var(--ease-out),
    transform 700ms var(--ease-out);
}
.reveal.is-in {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ---------- "what we see" list ---------- */
.see-list {
  list-style: none;
  display: grid;
  gap: 0;
  counter-reset: see;
}
.see-list li {
  counter-increment: see;
  display: grid;
  gap: var(--space-3);
  padding-block: var(--space-6);
  border-top: 1px solid var(--color-divider);
  align-items: baseline;
}
@media (min-width: 800px) {
  .see-list li {
    grid-template-columns: 4rem minmax(0, 1fr) minmax(0, 1.1fr);
    gap: var(--space-8);
  }
}
.see-list li::before {
  content: '0' counter(see);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--color-text-faint);
}
.see-list h3 {
  font-size: var(--text-lg);
  font-weight: 700;
}
.see-list p {
  color: var(--color-text-muted);
  font-size: var(--text-base);
  margin: 0;
}

/* ---------- work cards ---------- */
.work-grid {
  display: grid;
  gap: clamp(var(--space-6), 2.5vw, var(--space-10));
}
@media (min-width: 860px) {
  .work-grid {
    grid-template-columns: repeat(6, 1fr);
  }
  .work-card {
    grid-column: span 3;
  }
  .work-card--wide {
    grid-column: span 6;
  }
  .work-card--third {
    grid-column: span 2;
  }
}
.work-card {
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition:
    border-color var(--transition-interactive),
    transform var(--transition-interactive),
    box-shadow var(--transition-interactive);
}
.work-card:hover {
  border-color: var(--color-primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.work-card--wide {
  flex-direction: column;
}
@media (min-width: 860px) {
  .work-card--wide {
    flex-direction: row;
    align-items: stretch;
  }
  .work-card--wide .work-card__figure {
    flex: 1 1 58%;
    aspect-ratio: auto;
  }
  .work-card--wide .work-card__body {
    flex: 1 1 42%;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  .work-card--wide .work-card__body .link-arrow {
    margin-top: var(--space-2);
  }
}
.work-card__figure {
  position: relative;
  margin: 0;
  overflow: hidden;
  background: var(--color-surface-2);
  border-bottom: 1px solid var(--color-divider);
}
.work-card__figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  aspect-ratio: 16 / 10;
  transition: transform 600ms var(--ease-out);
}
.work-card--wide .work-card__figure img {
  height: auto;
  aspect-ratio: 16 / 10;
}
.work-card:hover .work-card__figure img {
  transform: scale(1.03);
}
.work-card__kicker {
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-text-faint);
}
.work-card__body {
  padding: clamp(var(--space-5), 2vw, var(--space-8));
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  flex: 1 1 auto;
}
.work-card__body h3 {
  font-size: var(--text-lg);
}
.work-card__body p {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  margin: 0;
}
.work-card__body .link-arrow {
  margin-top: auto;
  padding-top: var(--space-2);
  align-self: flex-start;
}
.figcap {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  padding: var(--space-2) var(--space-3);
}

/* ---------- capability grid ---------- */
.cap-grid {
  display: grid;
  gap: 1px;
  background: var(--color-divider);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
@media (min-width: 640px) {
  .cap-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1000px) {
  .cap-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
.cap {
  background: var(--color-surface);
  padding: clamp(var(--space-5), 2vw, var(--space-8));
  display: grid;
  gap: var(--space-2);
  align-content: start;
}
.cap span {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--color-gold);
}
.cap h3 {
  font-size: var(--text-base);
  font-weight: 700;
  font-family: var(--font-body);
  letter-spacing: 0;
}
.cap p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 0;
}

/* ---------- two-column editorial ---------- */
.split {
  display: grid;
  gap: clamp(var(--space-8), 4vw, var(--space-16));
  align-items: start;
}
@media (min-width: 900px) {
  .split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .split--sticky > :first-child {
    position: sticky;
    top: 7rem;
  }
  .split--wide-right {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  }
}

.prose > * + * {
  margin-top: var(--space-4);
}
.prose h2 {
  font-size: var(--text-xl);
  margin-top: var(--space-12);
}
.prose h3 {
  font-size: var(--text-lg);
  margin-top: var(--space-10);
}
.prose p,
.prose li {
  color: var(--color-text-muted);
}
.prose strong {
  color: var(--color-text);
}
.prose ul,
.prose ol {
  padding-left: 1.15rem;
  display: grid;
  gap: var(--space-2);
}
.prose blockquote {
  border-left: 2px solid var(--color-gold-bright);
  padding-left: var(--space-5);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-lg);
  line-height: 1.35;
  color: var(--color-text);
}
.prose blockquote p {
  color: inherit;
  max-width: 40ch;
}

/* checklists */
.ticks {
  list-style: none;
  display: grid;
  gap: var(--space-3);
  padding: 0;
}
.ticks li {
  display: grid;
  grid-template-columns: 1.1rem minmax(0, 1fr);
  gap: var(--space-3);
  font-size: var(--text-base);
  color: var(--color-text-muted);
}
.ticks li::before {
  content: '';
  width: 0.55rem;
  height: 0.55rem;
  margin-top: 0.55em;
  border: 1.5px solid var(--color-cyan);
  border-radius: 2px;
}

/* pill list */
.pills {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  padding: 0;
}
.pills li {
  font-size: var(--text-xs);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-family: var(--font-display);
  font-weight: 600;
  padding: 0.45em 0.85em;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
}

/* ---------- article / index cards ---------- */
.card-grid {
  display: grid;
  gap: clamp(var(--space-5), 2vw, var(--space-8));
}
@media (min-width: 700px) {
  .card-grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 900px) {
  .card-grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}
.card {
  display: grid;
  gap: var(--space-3);
  align-content: start;
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  padding: clamp(var(--space-5), 2vw, var(--space-8));
  transition:
    border-color var(--transition-interactive),
    transform var(--transition-interactive);
}
a.card:hover {
  border-color: var(--color-primary);
  transform: translateY(-3px);
}
.card h3 {
  font-size: var(--text-lg);
}
.card p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 0;
}
.card__meta {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-gold);
}

/* ---------- page hero (interior) ---------- */
.page-hero {
  padding-block: clamp(var(--space-12), 7vw, var(--space-24)) clamp(var(--space-8), 4vw, var(--space-12));
  border-bottom: 1px solid var(--color-divider);
}
.page-hero h1 {
  font-size: var(--text-2xl);
  max-width: 26ch;
}
.page-hero .lede {
  margin-top: var(--space-6);
}
.crumb {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text-faint);
  margin-bottom: var(--space-5);
}
.crumb a:hover {
  color: var(--color-primary);
}

/* ---------- case study spec table ---------- */
.spec {
  border-top: 1px solid var(--color-divider);
}
.spec div {
  display: grid;
  gap: var(--space-1);
  padding-block: var(--space-4);
  border-bottom: 1px solid var(--color-divider);
}
@media (min-width: 560px) {
  .spec div {
    grid-template-columns: 10rem minmax(0, 1fr);
    gap: var(--space-6);
  }
}
.spec dt {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text-faint);
}
.spec dd {
  font-size: var(--text-sm);
  color: var(--color-text);
}

.figure-block {
  margin: 0;
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-surface);
}
.figure-block img {
  width: 100%;
}
.figure-block figcaption {
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-divider);
}

.asset-slot {
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-lg);
  padding: clamp(var(--space-6), 3vw, var(--space-10));
  background: var(--color-surface-2);
  display: grid;
  gap: var(--space-2);
}
.asset-slot span {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-gold);
}
.asset-slot p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin: 0;
}

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--color-ink-block);
  color: #fff;
  border-radius: 0;
}
.cta-band h2 {
  font-size: var(--text-2xl);
  color: #fff;
  max-width: 22ch;
}
.cta-band p {
  color: #aebac3;
  margin-top: var(--space-5);
  font-size: var(--text-base);
}
.cta-band .btn--ghost {
  border-color: rgb(255 255 255 / 0.35);
  color: #fff;
}
.cta-band .btn--ghost:hover {
  border-color: #fff;
  color: #fff;
}

/* ---------- contact form ---------- */
.form {
  display: grid;
  gap: var(--space-5);
}
.field {
  display: grid;
  gap: var(--space-2);
}
.field label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.field input,
.field textarea,
.field select {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 0.8em 0.9em;
  font-size: var(--text-base);
}
.field input:focus-visible,
.field textarea:focus-visible,
.field select:focus-visible {
  border-color: var(--color-cyan);
}
.field textarea {
  min-height: 8rem;
  resize: vertical;
}
.form__note {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}
.form-status {
  font-size: var(--text-sm);
  color: var(--color-primary);
  min-height: 1.5em;
}

.steps {
  list-style: none;
  counter-reset: step;
  display: grid;
  gap: var(--space-5);
  padding: 0;
}
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr);
  column-gap: var(--space-4);
  row-gap: 0;
  align-items: start;
}
.steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--color-gold-bright);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-gold);
}
.steps p {
  grid-column: 2;
  margin: var(--space-1) 0 0;
  color: var(--color-text-muted);
  font-size: var(--text-sm);
}
.steps strong {
  grid-column: 2;
  display: block;
  color: var(--color-text);
  font-size: var(--text-base);
}

/* ---------- footer ---------- */
.site-footer {
  background: var(--color-ink-block);
  color: #9fadb7;
  padding-block: clamp(var(--space-12), 6vw, var(--space-20)) var(--space-8);
}
.site-footer a {
  color: #cfd8de;
}
.site-footer a:hover {
  color: #fff;
}
.footer__grid {
  display: grid;
  gap: clamp(var(--space-8), 4vw, var(--space-16));
}
@media (min-width: 800px) {
  .footer__grid {
    grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(0, 1fr));
  }
}
.footer__brand .brand {
  color: #fff;
}
.footer__brand .brand__logo {
  height: 1.9rem;
}
.footer__brand p {
  margin-top: var(--space-4);
  font-size: var(--text-sm);
  color: #8fa0ab;
  max-width: 34ch;
}
.footer__col h4 {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: var(--space-4);
}
.footer__col ul {
  list-style: none;
  display: grid;
  gap: var(--space-2);
  font-size: var(--text-sm);
}
.footer__bottom {
  margin-top: clamp(var(--space-10), 5vw, var(--space-16));
  padding-top: var(--space-6);
  border-top: 1px solid rgb(255 255 255 / 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  font-size: var(--text-xs);
  color: #7d8d98;
}

/* ---------- hero fluid effect (homepage only) ---------- */
.hero--fx {
  background-color: #07161f;
  color: var(--color-text-inverse);
  isolation: isolate;
}
.hero__fx {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  /* static fallback: shown as-is for reduced-motion or no-WebGL visitors */
  background:
    radial-gradient(85% 70% at 68% 42%, rgb(44 166 222 / 0.3) 0%, rgb(44 166 222 / 0) 60%),
    radial-gradient(70% 60% at 22% 78%, rgb(13 82 112 / 0.65) 0%, rgb(13 82 112 / 0) 65%),
    radial-gradient(55% 55% at 88% 88%, rgb(91 110 225 / 0.22) 0%, rgb(91 110 225 / 0) 60%),
    #07161f;
}
.hero__fx-canvas {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}
.hero__fx-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(100deg, rgb(6 20 28 / 0.88) 0%, rgb(6 20 28 / 0.6) 34%, rgb(6 20 28 / 0.06) 62%, rgb(6 20 28 / 0.3) 100%),
    linear-gradient(to bottom, rgb(6 20 28 / 0.4) 0%, rgb(6 20 28 / 0) 28%, rgb(6 20 28 / 0.5) 100%);
}
.hero--fx > .shell {
  position: relative;
  z-index: 1;
}
.hero--fx h1,
.hero--fx .hero__meta div span {
  color: #fff;
}
.hero--fx .eyebrow {
  color: #7fd0f2;
}
.hero--fx .hero__copy {
  color: #cddce6;
}
.hero--fx .hero__meta {
  border-top-color: rgb(255 255 255 / 0.18);
}
.hero--fx .hero__meta div small {
  color: #8ea3b1;
}
.hero--fx .hero__mark-rule {
  background: rgb(255 255 255 / 0.22);
}
.hero--fx .hero__knot {
  filter: drop-shadow(0 0 28px rgb(44 166 222 / 0.45));
}
.hero--fx .btn--ghost {
  color: #fff;
  border-color: rgb(255 255 255 / 0.45);
}
.hero--fx .btn--ghost:hover {
  background: rgb(255 255 255 / 0.1);
  border-color: #fff;
}
@media (prefers-reduced-motion: reduce) {
  .hero__fx-canvas {
    display: none;
  }
}

/* ------------------------------------------------------------ portfolio
   Cinematic depth-gallery page. The WebGL field lives in a fixed stage;
   chapter copy scrolls above it. Without JS/WebGL (or with reduced motion)
   the same real photography renders as a static editorial grid. */
.work {
  --work-bg: #f7f6f3;
  --work-ink: #131f28;
  position: relative;
  background: var(--work-bg);
  color: var(--work-ink);
  transition: background-color 0.6s linear;
}
.work__stage {
  display: none;
}
.work[data-work-fx='on'] .work__stage {
  display: block;
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  margin-bottom: -100vh;
  z-index: 0;
  pointer-events: none;
}
.work__canvas {
  display: block;
  width: 100%;
  height: 100%;
}
/* scrim holds the opening headline legible over a light-value photograph,
   then clears as the pull-back finishes (--work-cue is hero progress 0..1) */
.work[data-work-fx='on'] .work__stage::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    rgba(8, 12, 16, 0.74) 0%,
    rgba(8, 12, 16, 0.4) 46%,
    rgba(8, 12, 16, 0) 74%
  );
  opacity: calc(1 - var(--work-cue, 0));
}
@media (max-width: 819px) {
  .work[data-work-fx='on'] .work__stage::after {
    background: linear-gradient(
      180deg,
      rgba(8, 12, 16, 0.62) 0%,
      rgba(8, 12, 16, 0.52) 55%,
      rgba(8, 12, 16, 0.2) 100%
    );
  }
}
.work__flow {
  position: relative;
  z-index: 1;
}
.work__chapter,
.work__hero,
.work__finale {
  position: relative;
}
.work__hero {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-content: center;
  padding-inline: var(--gutter);
  padding-block: clamp(var(--space-20), 12vw, var(--space-32));
}
.work__hero-inner {
  max-width: 60rem;
}
.work__eyebrow {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--work-ink);
  opacity: 0.62;
  margin-bottom: var(--space-6);
}
.work__title {
  font-family: var(--font-display);
  font-size: var(--text-3xl);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0 0 var(--space-8);
  color: var(--work-ink);
}
.work__lede {
  font-size: var(--text-lg);
  line-height: 1.5;
  max-width: 44ch;
  color: var(--work-ink);
  opacity: 0.82;
}
.work__cue {
  margin-top: clamp(var(--space-10), 6vw, var(--space-20));
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--work-ink);
  opacity: 0.7;
}
.work__cue-track {
  display: block;
  width: 5.5rem;
  height: 2px;
  background: currentColor;
  opacity: 0.28;
  position: relative;
  overflow: hidden;
}
.work__cue-track::after {
  content: '';
  position: absolute;
  inset: 0;
  transform: scaleX(var(--work-cue, 0));
  transform-origin: left;
  background: currentColor;
  opacity: 1;
}
.work__chapter {
  padding-inline: var(--gutter);
  padding-block: clamp(var(--space-16), 9vw, var(--space-24));
}
.work[data-work-fx='on'] .work__chapter {
  min-height: 300vh;
  display: grid;
  align-content: space-between;
  gap: 100vh;
}
.work__panel {
  max-width: 34rem;
}
.work__panel--right {
  margin-left: auto;
}
.work__chapter-label {
  display: flex;
  align-items: baseline;
  gap: var(--space-4);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: var(--space-5);
  opacity: 0.68;
}
.work__chapter-title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.015em;
  margin: 0 0 var(--space-5);
}
.work__panel p {
  font-size: var(--text-base);
  line-height: 1.6;
  opacity: 0.84;
  margin: 0 0 var(--space-5);
}
.work__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-2);
  font-size: var(--text-sm);
}
.work__list li {
  padding-left: var(--space-5);
  position: relative;
  opacity: 0.86;
}
.work__list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 0.5rem;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}
/* readable scrim so copy holds over the moving field */
.work[data-work-fx='on'] .work__panel {
  padding: clamp(var(--space-5), 2.5vw, var(--space-8));
  background: color-mix(in srgb, var(--work-bg) 74%, transparent);
  backdrop-filter: blur(14px) saturate(1.1);
  border: 1px solid color-mix(in srgb, var(--work-ink) 14%, transparent);
  will-change: filter;
}
@supports not (backdrop-filter: blur(4px)) {
  .work[data-work-fx='on'] .work__panel {
    background: color-mix(in srgb, var(--work-bg) 92%, transparent);
  }
}
/* static editorial grid — the no-JS / reduced-motion / context-loss surface */
.work__plates {
  margin-top: clamp(var(--space-10), 5vw, var(--space-16));
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr));
  gap: clamp(var(--space-4), 2vw, var(--space-8));
}
.work[data-work-fx='on'] .work__plates {
  display: none;
}
.work__plate {
  margin: 0;
}
.work__plate img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: color-mix(in srgb, var(--work-ink) 12%, transparent);
}
.work__plate figcaption {
  font-size: var(--text-xs);
  line-height: 1.5;
  margin-top: var(--space-3);
  opacity: 0.7;
}
.work__rail {
  display: none;
}
.work[data-work-fx='on'] .work__rail {
  display: grid;
  gap: var(--space-3);
  position: fixed;
  right: clamp(0.9rem, 2vw, 2rem);
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  pointer-events: none;
}
.work__rail span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--work-ink);
  opacity: 0.26;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.work__rail span.is-active {
  opacity: 1;
  transform: scale(1.5);
}
.work__finale {
  padding-inline: var(--gutter);
  padding-block: clamp(var(--space-16), 10vw, var(--space-32));
  display: grid;
  align-content: center;
  text-align: center;
  justify-items: center;
}
.work[data-work-fx='on'] .work__finale {
  min-height: 160vh;
  align-content: start;
  padding-top: 0;
}
.work[data-work-fx='on'] .work__finale-line {
  position: sticky;
  top: 14vh;
}
.work__finale-line {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  max-width: 40ch;
  margin: 0;
}
@media (max-width: 819px) {
  .work[data-work-fx='on'] .work__chapter {
    min-height: 190vh;
    gap: 60vh;
  }
  .work[data-work-fx='on'] .work__finale {
    min-height: 110vh;
  }
  .work__panel--right {
    margin-left: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .work__stage,
  .work[data-work-fx='on'] .work__stage {
    display: none;
  }
  .work,
  .work__chapter {
    transition: none;
  }
}

/* flat index of engagements below the cinematic chapters */
.work-outro {
  position: relative;
  z-index: 2;
  background: var(--color-bg);
}
.work-index {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--color-divider);
}
.work-index li {
  border-bottom: 1px solid var(--color-divider);
}
.work-index a {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-4);
  align-items: baseline;
  padding-block: clamp(var(--space-5), 2.2vw, var(--space-8));
  text-decoration: none;
  color: inherit;
  transition: padding-left 0.35s ease, color 0.35s ease;
}
.work-index a:hover {
  padding-left: var(--space-4);
  color: var(--color-primary);
}
.work-index strong {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.work-index span {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
@media (max-width: 700px) {
  .work-index a {
    grid-template-columns: 1fr;
    gap: var(--space-1);
  }
}

/* print-safe hairline utility */
.hr {
  height: 1px;
  background: var(--color-divider);
  border: 0;
  margin-block: clamp(var(--space-10), 5vw, var(--space-16));
}
