:root {
  --paper: #f7f1f7;
  --paper-rgb: 247, 241, 247;
  --paper-2: #fbf7fb;
  --ink: #17161b;
  --ink-2: #242229;
  --muted: #6f6872;
  --line: rgba(23, 22, 27, 0.11);
  --dark: #18171d;
  --dark-soft: #232229;
  --accent: #dd654f;
  --accent-dark: #be4937;
  --sage: #6d887a;
  --white: #ffffff;
  --hero-wash-start: rgba(var(--paper-rgb), 0.78);
  --hero-wash-mid: rgba(var(--paper-rgb), 0.34);
  --hero-wash-end: rgba(var(--paper-rgb), 0.02);
  --hero-shadow: rgba(224, 215, 226, 0.75);
  --header-bg: rgba(var(--paper-rgb), 0.92);
  --serif: Georgia, "Times New Roman", Times, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="editorial"] {
  --paper: #151316;
  --paper-rgb: 21, 19, 22;
  --paper-2: #201b1d;
  --ink: #f7efe4;
  --ink-2: #e5d9c9;
  --muted: #b8aa9a;
  --line: rgba(247, 239, 228, 0.14);
  --dark: #0d0c0e;
  --dark-soft: #171416;
  --accent: #c47a4b;
  --accent-dark: #a96035;
  --sage: #c47a4b;
  --white: #fbf6ee;
  --serif: "Playfair Display", Georgia, "Times New Roman", Times, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --hero-wash-start: rgba(21, 19, 22, 0.72);
  --hero-wash-mid: rgba(21, 19, 22, 0.32);
  --hero-wash-end: rgba(21, 19, 22, 0.02);
  --hero-shadow: rgba(196, 122, 75, 0.28);
  --header-bg: rgba(21, 19, 22, 0.9);
}

html[data-theme="tech"] {
  --paper: #f5f7f2;
  --paper-rgb: 245, 247, 242;
  --paper-2: #ffffff;
  --ink: #111419;
  --ink-2: #27313f;
  --muted: #60707d;
  --line: rgba(17, 20, 25, 0.12);
  --dark: #111419;
  --dark-soft: #1d2530;
  --accent: #1f7aff;
  --accent-dark: #075fdb;
  --sage: #99c24d;
  --white: #ffffff;
  --serif: "Space Grotesk", Inter, ui-sans-serif, system-ui, sans-serif;
  --sans: Manrope, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --hero-wash-start: rgba(245, 247, 242, 0.8);
  --hero-wash-mid: rgba(245, 247, 242, 0.35);
  --hero-wash-end: rgba(245, 247, 242, 0.01);
  --hero-shadow: rgba(31, 122, 255, 0.18);
  --header-bg: rgba(245, 247, 242, 0.92);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  line-height: 1.5;
  text-rendering: geometricPrecision;
}
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; max-width: 100%; }
figure, h1, h2, h3, p, ol { margin: 0; }
main, section, article, figure, div { min-width: 0; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto minmax(170px, 1fr);
  align-items: center;
  gap: 28px;
  min-height: 72px;
  padding: 13px clamp(24px, 7vw, 118px);
  border-bottom: 1px solid var(--line);
  background: var(--header-bg);
  backdrop-filter: blur(18px);
}
.brand {
  width: max-content;
  font-family: var(--serif);
  font-size: clamp(20px, 1.9vw, 28px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-transform: uppercase;
}
nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 3vw, 38px);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
nav a {
  position: relative;
  padding: 8px 0;
}
nav a.active::after,
nav a:hover::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 1px;
  background: var(--ink);
}
.header-cta {
  justify-self: end;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  background: var(--accent);
  color: var(--white);
  font-size: 12px;
  font-weight: 800;
  border: 1px solid var(--accent);
  transition: transform 180ms ease, background-color 180ms ease;
}

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 0.93fr) minmax(340px, 0.9fr);
  align-items: center;
  gap: clamp(42px, 8vw, 116px);
  padding: clamp(58px, 8vw, 92px) clamp(24px, 7vw, 118px) clamp(70px, 9vw, 110px);
}
.hero-copy { position: relative; z-index: 2; max-width: 610px; }
.eyebrow {
  margin-bottom: 19px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.secondary-word {
  color: var(--sage);
  font-style: italic;
  font-family: inherit;
}

h1, h2, h3 { font-family: var(--serif); font-weight: 900; letter-spacing: 0; }
h1 {
  max-width: 620px;
  font-size: clamp(54px, 7vw, 91px);
  line-height: 0.91;
}
.lead {
  max-width: 560px;
  margin-top: 30px;
  color: var(--ink-2);
  font-size: clamp(16px, 1.24vw, 19px);
  line-height: 1.55;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 38px;
}
.button {
  min-height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 29px;
  border: 1px solid var(--ink);
  font-size: 13px;
  font-weight: 900;
  transition: transform 180ms ease, background-color 180ms ease, color 180ms ease;
}
.button.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--white);
}
.button.secondary { background: transparent; color: var(--ink); }
.hero-visual {
  position: relative;
  z-index: 2;
  width: min(100%, 620px);
  justify-self: end;
  background: var(--white);
  box-shadow: -31px 31px 0 var(--hero-shadow);
  overflow: hidden;
}
.hero-photo {
  aspect-ratio: 4 / 3;
  min-height: 0;
  object-fit: cover;
  object-position: center center;
}
.photo-caption {
  position: absolute;
  left: 18px;
  bottom: 18px;
  max-width: calc(100% - 36px);
  padding: 10px 12px;
  background: rgba(12, 12, 14, 0.76);
  color: var(--white);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.54;
  background:
    radial-gradient(circle at 18% 26%, rgba(221, 101, 79, 0.38) 0 2px, transparent 3px),
    radial-gradient(circle at 72% 34%, rgba(79, 116, 101, 0.34) 0 2px, transparent 3px),
    linear-gradient(115deg, transparent 0 23%, rgba(221, 101, 79, 0.16) 23.2%, transparent 24%, transparent 48%, rgba(79, 116, 101, 0.18) 48.2%, transparent 49%);
  background-size: 96px 96px, 132px 132px, 220px 220px;
  animation: hero-network-drift 9s linear infinite;
}

.process::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.28;
  background: linear-gradient(110deg, transparent 12%, rgba(221, 101, 79, 0.48) 12.4%, transparent 13%, transparent 50%, rgba(79, 116, 101, 0.42) 50.4%, transparent 51%);
  background-size: 260px 260px;
  animation: none;
}

.webgl-live::before { opacity: 0.22; }
@keyframes hero-network-drift {
  from { background-position: 0 0, 0 0, 0 0; }
  to { background-position: 96px -96px, -132px 132px, 220px -220px; }
}
@keyframes process-trace-drift {
  from { background-position: 0 0; }
  to { background-position: 260px -260px; }
}



.webgl-status {
  position: absolute;
  left: clamp(16px, 4vw, 54px);
  bottom: 18px;
  z-index: 5;
  max-width: min(430px, calc(100% - 32px));
  padding: 10px 12px;
  border: 1px solid rgba(23, 22, 27, 0.16);
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  box-shadow: 0 12px 34px rgba(23, 22, 27, 0.14);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}
.webgl-status.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.webgl-status[data-state="blocked"] {
  border-color: rgba(190, 73, 55, 0.38);
  color: var(--accent-dark);
}
.webgl-status[data-state="ready"] {
  border-color: rgba(79, 116, 101, 0.34);
  color: var(--sage);
}

.webgl-hero {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.webgl-hero {
  z-index: 0;
  opacity: 1;
  mix-blend-mode: normal;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(90deg, var(--hero-wash-start) 0%, var(--hero-wash-mid) 42%, var(--hero-wash-end) 100%);
}
.hero.webgl-live::after {
  background: linear-gradient(90deg, var(--hero-wash-start) 0%, var(--hero-wash-mid) 43%, var(--hero-wash-end) 100%);
}
.hero-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255,255,255,0.24), rgba(255,255,255,0) 38%);
}
.motion-ready .reveal-media,
.motion-ready .archive a {
  opacity: 0;
  transform: translateY(18px) scale(0.985);
  transition: opacity 700ms ease, transform 700ms ease, filter 700ms ease;
}
.motion-ready .reveal-media.is-visible,
.motion-ready .archive a.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.archive a:nth-child(2) { transition-delay: 80ms; }
.archive a:nth-child(3) { transition-delay: 140ms; }
.archive a:nth-child(4) { transition-delay: 200ms; }

.trusted {
  padding: 54px clamp(24px, 7vw, 118px) 58px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,0.22);
  text-align: center;
}
.trusted p {
  margin-bottom: 30px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.brand-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: center;
  gap: 26px;
  font-family: var(--serif);
  font-size: clamp(20px, 2vw, 30px);
  font-weight: 500;
}

.section { padding: clamp(76px, 10vw, 134px) clamp(24px, 7vw, 118px); }
#portfolio,
#case-studies,
#services,
#process,
#about,
#contact,
#archive {
  scroll-margin-top: 104px;
}

.portfolio-intro {
  min-height: 360px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) auto;
  justify-content: space-between;
  align-items: end;
  gap: 30px;
}
h2 {
  font-size: clamp(38px, 4.8vw, 68px);
  line-height: 1;
}
.portfolio-note {
  max-width: 620px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}
.text-link {
  margin-top: 42px;
  border-bottom: 1px solid currentColor;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.edge {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(360px, 0.82fr);
  align-items: center;
  gap: clamp(44px, 7vw, 106px);
  padding: clamp(70px, 9vw, 118px) clamp(24px, 7vw, 118px);
  background: var(--dark);
  color: var(--white);
}
.edge .eyebrow { color: #cfc8d2; }
.edge h2 {
  max-width: 560px;
  font-size: clamp(40px, 4.8vw, 70px);
}
.edge-copy > p:not(.eyebrow) {
  max-width: 620px;
  margin-top: 30px;
  color: rgba(255,255,255,0.77);
  font-size: 16px;
  line-height: 1.6;
}
.metrics {
  display: flex;
  gap: clamp(44px, 8vw, 112px);
  margin-top: 44px;
}
.metrics strong {
  display: block;
  font-family: var(--serif);
  font-size: clamp(36px, 4.2vw, 58px);
  line-height: 0.82;
}
.metrics span {
  display: block;
  margin-top: 8px;
  color: rgba(255,255,255,0.72);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.edge-frame {
  border: 1px solid rgba(255,255,255,0.12);
  background: var(--dark-soft);
  padding: 19px;
}
.edge-photo {
  aspect-ratio: 3 / 4;
  min-height: 0;
  max-height: 640px;
  object-fit: cover;
  object-position: center top;
  filter: saturate(0.9) contrast(0.97);
}
.comparison {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  min-height: 340px;
  overflow: hidden;
}
.comparison div {
  position: relative;
  min-height: 340px;
  background: #7b7b77;
  overflow: hidden;
}
.comparison div:last-child { background: #93b7ad; }
.comparison span {
  position: absolute;
  top: 13px;
  left: 13px;
  z-index: 2;
  padding: 7px 10px;
  background: rgba(12, 12, 14, 0.74);
  color: var(--white);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.comparison img {
  height: 100%;
  object-fit: cover;
  object-position: top center;
  opacity: 0.64;
  filter: grayscale(0.25) contrast(0.88);
}
.comparison div:last-child img {
  opacity: 0.86;
  filter: saturate(0.82) contrast(0.93);
}
.edge-frame figcaption {
  padding-top: 13px;
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  text-align: center;
}

.services {
  min-height: 780px;
  text-align: center;
}
.services > .eyebrow { margin-bottom: 14px; }
.services h2 { max-width: 760px; margin: 0 auto; }
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: clamp(54px, 7vw, 92px);
  text-align: left;
}
.service-grid article {
  min-height: 300px;
  padding: 28px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.36);
}
.service-grid span,
.process li span {
  display: block;
  margin-bottom: 66px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}
.service-grid h3 { font-size: clamp(25px, 2.4vw, 36px); line-height: 1; }
.service-grid p,
.process li p {
  margin-top: 18px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.archive {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1px;
  padding: 1px;
  background: var(--line);
}
.archive a {
  background: var(--paper-2);
  padding: clamp(18px, 3vw, 32px);
}
.archive .visual-wide { grid-column: span 6; }
.archive .visual-wide:last-child { grid-column: span 12; }
.archive .visual-tall { grid-column: span 3; }
.archive img {
  width: 100%;
  object-fit: cover;
  filter: saturate(0.86);
}
.archive .visual-wide img {
  aspect-ratio: 16 / 9;
  object-position: center center;
}
.archive .visual-tall img {
  aspect-ratio: 3 / 4;
  object-position: center top;
}
.archive p {
  margin-top: 22px;
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.archive h3 {
  margin-top: 8px;
  font-size: clamp(26px, 3vw, 43px);
}

.archive a > span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  margin-top: 18px;
  border-bottom: 1px solid currentColor;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.process {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(70px, 9vw, 120px) clamp(24px, 7vw, 118px);
  background: var(--paper-2);
  border-top: 1px solid var(--line);
}
.process > .eyebrow, .process h2, .process ol { position: relative; z-index: 2; }
.process h2 { max-width: 820px; }
.process ol {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 52px;
  padding: 0;
  list-style: none;
}
.process li {
  min-height: 260px;
  padding: 28px;
  border: 1px solid var(--line);
  background: var(--paper);
}
.process li strong {
  display: block;
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1;
}


.case-studies {
  padding: clamp(64px, 8vw, 112px) clamp(18px, 7vw, 118px);
  background: radial-gradient(circle at 82% 4%, rgba(196, 122, 75, 0.16), transparent 34%), var(--dark);
  color: var(--white);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
html[data-theme="tech"] .case-studies { background: var(--paper-2); color: var(--ink); }
.case-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.98fr) minmax(260px, 0.46fr);
  gap: 30px;
  align-items: end;
  margin-bottom: clamp(30px, 5vw, 64px);
}
.case-heading .eyebrow { grid-column: 1 / -1; margin-bottom: 0; color: var(--accent); }
.case-heading h2 { max-width: 860px; color: inherit; font-size: clamp(36px, 4.6vw, 68px); }
.case-heading p:not(.eyebrow) {
  max-width: 460px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 15px;
  line-height: 1.62;
}
.case-stack {
  display: grid;
  grid-template-columns: minmax(0, 1.38fr) minmax(280px, 0.82fr);
  gap: 18px;
  align-items: stretch;
}
.study-card {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.045);
  overflow: hidden;
}
.study-card-featured { grid-row: span 2; }
.study-card:nth-child(even) .study-media { order: 0; }
.study-media {
  min-height: 0;
  margin: 0;
  background: #191418;
  overflow: hidden;
}
.study-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  min-height: 0;
  object-fit: cover;
  object-position: center top;
  filter: saturate(0.94) contrast(0.98);
}
.study-card-featured .study-media img { aspect-ratio: 16 / 10; }
.study-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: clamp(20px, 2.8vw, 34px);
}
.study-copy span,
.package-grid span,
.proof-grid span,
.timeline span {
  display: block;
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.study-copy h3,
.package-grid h3,
.faq-list h3 {
  color: inherit;
  font-size: clamp(26px, 2.5vw, 38px);
  line-height: 1;
}
.study-result {
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.5;
}
.study-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: auto 0 0;
  padding: 22px 0 0;
  list-style: none;
}
.study-tags li {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 11px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.66);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}
.package-grid p,
.about-copy > p,
.proof-grid p,
.faq-list p,
.contact p,
.timeline p {
  margin-top: 16px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.58;
}

.packages,
.proof,
.faq,
.contact,
.about-section {
  padding: clamp(70px, 9vw, 118px) clamp(24px, 7vw, 118px);
  border-top: 1px solid var(--line);
}
.packages { background: var(--paper); }
.packages-heading,
.faq-heading {
  max-width: 780px;
  margin-bottom: 44px;
}
.package-grid,
.proof-grid,
.faq-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.package-grid article,
.proof-grid article,
.faq-list article {
  min-height: 230px;
  padding: 26px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.28);
}

.about-section {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(44px, 7vw, 96px);
  background: var(--dark);
  color: var(--white);
}
.about-portrait {
  border: 1px solid rgba(255,255,255,0.14);
  background: var(--dark-soft);
  padding: 18px;
}
.about-portrait img {
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center top;
}
.about-copy h2 { font-size: clamp(38px, 4.6vw, 68px); }
.about-copy > p { color: rgba(255,255,255,0.74); }
.timeline {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 38px;
  background: rgba(255,255,255,0.14);
}
.timeline article {
  padding: 22px;
  background: var(--dark-soft);
}
.timeline strong {
  display: block;
  font-family: var(--serif);
  font-size: 25px;
  line-height: 1.05;
}
.timeline p { color: rgba(255,255,255,0.66); }

.proof {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1fr);
  gap: clamp(34px, 6vw, 84px);
  align-items: start;
  background: var(--paper-2);
}
.proof h2 { font-size: clamp(38px, 4.8vw, 70px); }
.proof-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.proof-grid article { min-height: 190px; }
.proof-grid strong {
  display: block;
  font-family: var(--serif);
  font-size: clamp(26px, 2.4vw, 36px);
  line-height: 1;
}

.faq { background: var(--paper); }
.faq-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.faq-list article { min-height: 190px; }

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 34px;
  align-items: end;
  background: var(--accent);
  color: var(--white);
}
.contact .eyebrow { color: rgba(255,255,255,0.8); }
.contact h2 { max-width: 820px; }
.contact p { max-width: 620px; color: rgba(255,255,255,0.78); }
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}
.contact .button.primary {
  border-color: var(--white);
  background: var(--white);
  color: var(--accent-dark);
}
.contact .button.secondary {
  border-color: rgba(255,255,255,0.72);
  color: var(--white);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(220px, 0.7fr);
  gap: 28px;
  align-items: end;
  padding: clamp(66px, 8vw, 104px) clamp(24px, 7vw, 118px);
  background: var(--white);
  border-top: 1px solid var(--line);
}
.site-footer p {
  max-width: 420px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 14px;
}
.footer-links {
  justify-self: end;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 24px;
  font-size: 12px;
  font-weight: 800;
  text-decoration: underline;
}
.site-footer small {
  grid-column: 2;
  justify-self: end;
  color: #aaa0aa;
  font-size: 12px;
}

.header-cta:active,
.button:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) {
  .header-cta:hover,
  .button.primary:hover { background: var(--accent-dark); }
  .button.secondary:hover { background: var(--ink); color: var(--white); }
  .archive a, .service-grid article, .process li, .study-card, .package-grid article, .proof-grid article, .faq-list article { transition: transform 190ms ease, background-color 190ms ease, box-shadow 190ms ease; }
  .archive a:hover, .service-grid article:hover, .process li:hover, .study-card:hover, .package-grid article:hover, .proof-grid article:hover, .faq-list article:hover { transform: translateY(-2px); }
}

@media (max-width: 1060px) {
  .site-header { grid-template-columns: 1fr auto; }
  nav { order: 3; grid-column: 1 / -1; justify-content: flex-start; overflow-x: auto; }
  .hero, .edge { grid-template-columns: 1fr; }
  .hero-visual { justify-self: start; width: min(100%, 620px); }
  .portfolio-intro { min-height: 360px; }
  .brand-row, .service-grid, .process ol, .package-grid, .faq-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-heading, .study-card, .about-section, .proof, .contact { grid-template-columns: 1fr; }
  .study-card:nth-child(even) .study-media { order: 0; }
  .proof-grid { grid-template-columns: 1fr; }
  .contact-actions { justify-content: flex-start; }
  .archive { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .archive .visual-wide, .archive .visual-wide:last-child, .archive .visual-tall { grid-column: span 1; }
  .site-footer { grid-template-columns: 1fr; }
  .footer-links, .site-footer small { justify-self: start; grid-column: auto; }
}

@media (max-width: 680px) {
  .site-header { grid-template-columns: 1fr auto; gap: 12px; padding: 14px 18px; }
  .brand { font-size: 18px; }
  nav {
    order: 3;
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-start;
    gap: 20px;
    overflow-x: auto;
    padding: 6px 0 2px;
    color: var(--muted);
    scrollbar-width: none;
  }
  nav::-webkit-scrollbar { display: none; }
  nav a { flex: 0 0 auto; padding: 6px 0; }
  .header-cta { min-height: 40px; padding-inline: 13px; font-size: 11px; }
  .hero {
    min-height: auto;
    padding: 28px 7px 48px;
    gap: 24px;
  }
  .hero-copy { max-width: 100%; padding: 0 11px; }
  h1 { font-size: 42px; line-height: 0.94; }
  h2 { font-size: 40px; }
  .lead { margin-top: 22px; }
  .hero-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 30px;
  }
  .button {
    width: 100%;
    min-height: 52px;
    border-radius: 0;
  }
  .hero-visual {
    justify-self: center;
    width: 100%;
    box-shadow: none;
    margin-top: 6px;
  }
  .hero-photo {
    aspect-ratio: 1 / 1;
    min-height: 360px;
    max-height: 430px;
    object-position: 100% 50%;
  }
  .photo-caption { display: none; }
  .webgl-hero { z-index: 1; opacity: 1; mix-blend-mode: normal; }
  .hero.webgl-live::before { opacity: 0.52; }
  .hero::after { z-index: 0; background: linear-gradient(180deg, rgba(var(--paper-rgb), 0.5) 0%, rgba(var(--paper-rgb), 0.18) 48%, rgba(var(--paper-rgb), 0) 100%); }
  .hero.webgl-live::after { background: linear-gradient(180deg, rgba(var(--paper-rgb), 0.42) 0%, rgba(var(--paper-rgb), 0.12) 50%, rgba(var(--paper-rgb), 0) 100%); }

  #portfolio,
  #case-studies,
  #services,
  #process,
  #about,
  #contact,
  #archive { scroll-margin-top: 126px; }
  .trusted, .section, .edge, .process, .site-footer, .case-studies, .packages, .about-section, .proof, .faq, .contact { padding-left: 18px; padding-right: 18px; }
  .brand-row, .service-grid, .process ol, .case-heading, .case-stack, .study-card, .package-grid, .about-section, .timeline, .proof, .proof-grid, .faq-list, .contact { grid-template-columns: 1fr; }
  .archive { grid-template-columns: 1fr; }
  .archive .visual-wide, .archive .visual-wide:last-child, .archive .visual-tall { grid-column: span 1; }
  .archive .visual-wide img { aspect-ratio: 4 / 3; }
  .archive h3 { font-size: 36px; line-height: 1.02; }
  .archive a > span { margin-top: 14px; }
  .case-stack { gap: 18px; grid-template-columns: 1fr; }
  .study-card { padding: 0; box-shadow: none; }
  .study-media { min-height: 245px; }
  .study-media img { min-height: 245px; }
  .study-copy { padding: 18px 10px 14px; }
  .study-copy h3 { font-size: 34px; }
  .case-heading h2 { font-size: 36px; line-height: 1.04; }
  .case-heading p:not(.eyebrow) { font-size: 14px; }
  .study-result { font-size: 16px; }
  .study-points div { grid-template-columns: 1fr; gap: 6px; }
  .detail-grid { grid-template-columns: 1fr; }
  .contact-actions { justify-content: flex-start; }
  .portfolio-intro { min-height: 280px; display: block; }
  .text-link { display: inline-flex; margin-top: 34px; }
  .edge { gap: 40px; }
  .metrics { gap: 34px; }
  .comparison, .comparison div { min-height: 260px; }
  .services { min-height: auto; }
  .service-grid span, .process li span { margin-bottom: 42px; }
  .footer-links { gap: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .webgl-hero { display: none; }
  .motion-ready .reveal-media, .motion-ready .archive a { opacity: 1; transform: none; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}
