:root {
  /* Single-theme tokens: off-black, pearl, chrome, and one lime accent. */
  --bg: #050505;
  --surface: #0a0a0a;
  --surface-2: #101010;
  --ink: #f2f2ed;
  --muted: #8d8d87;
  --dim: #585854;
  --line: rgba(255, 255, 255, 0.13);
  --line-soft: rgba(255, 255, 255, 0.075);
  --accent: #c8ff3d;
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", "Helvetica Neue", sans-serif;
  --header-h: 72px;
  --sidebar-w: 208px;
  --page-x: clamp(1.25rem, 4vw, 4.5rem);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 70% 4%, rgba(255, 255, 255, 0.045), transparent 28rem),
    var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::after {
  position: fixed;
  z-index: 30;
  inset: 0;
  pointer-events: none;
  opacity: 0.17;
  content: "";
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.72' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.23'/%3E%3C/svg%3E");
  mix-blend-mode: soft-light;
}

::selection {
  color: #050505;
  background: var(--accent);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
  font: inherit;
}

img,
canvas {
  display: block;
  max-width: 100%;
}

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  transform: translateY(-150%);
  background: var(--accent);
  color: #050505;
  font-weight: 700;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-loader {
  --loader-progress: 0;
  position: fixed;
  z-index: 90;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #050505;
  clip-path: inset(0 0 0 0);
  transition: clip-path 1s cubic-bezier(0.76, 0, 0.24, 1), visibility 1s;
}

.site-loader.done {
  visibility: hidden;
  clip-path: inset(0 0 100% 0);
}

body.is-loading {
  overflow: hidden;
}

.loader-kicker,
.loader-meta {
  position: absolute;
  right: clamp(1.25rem, 3.5vw, 3.5rem);
  left: clamp(1.25rem, 3.5vw, 3.5rem);
  display: flex;
  justify-content: space-between;
  color: rgba(242, 242, 237, 0.38);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.loader-kicker {
  top: clamp(1.5rem, 4vw, 3.5rem);
}

.loader-meta {
  bottom: clamp(1.8rem, 4vw, 3.75rem);
}

.loader-meta span {
  flex: 1;
}

.loader-meta span:nth-child(2) {
  text-align: center;
}

.loader-meta span:last-child {
  text-align: right;
}

.loader-core {
  display: grid;
  justify-items: center;
  transform: translateY(-1vh);
}

.loader-mark {
  margin-bottom: clamp(1.25rem, 2.5vw, 2.25rem);
  color: rgba(242, 242, 237, 0.48);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.32em;
}

.loader-count {
  display: flex;
  align-items: flex-start;
  min-width: 3ch;
  margin: 0;
  font-family: var(--serif);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.075em;
  line-height: 0.76;
}

.loader-count strong {
  min-width: 2.1ch;
  font-size: clamp(5.5rem, 14vw, 12rem);
  font-weight: 400;
  text-align: right;
}

.loader-count small {
  margin: 0.3em 0 0 0.35em;
  color: rgba(242, 242, 237, 0.5);
  font-family: var(--sans);
  font-size: clamp(0.7rem, 1.2vw, 0.9rem);
  font-weight: 500;
  letter-spacing: 0.12em;
}

.loader-line {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: rgba(242, 242, 237, 0.16);
}

.loader-line i {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(var(--loader-progress));
  transform-origin: left;
  background: var(--ink);
  transition: transform 0.1s linear;
}

@media (max-width: 640px) {
  .loader-kicker span:last-child {
    display: none;
  }

  .loader-meta {
    letter-spacing: 0.16em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-loader {
    transition-duration: 0.2s;
  }

  .loader-line i {
    transition: none;
  }
}

.site-header {
  /* System layer 40: persistent chrome above page content and canvas. */
  position: fixed;
  z-index: 40;
  top: 0;
  right: 0;
  left: 0;
  height: var(--header-h);
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr auto;
  align-items: center;
  gap: 2rem;
  padding: 0 var(--page-x);
  border-bottom: 1px solid var(--line-soft);
  background: rgba(5, 5, 5, 0.74);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: max-content;
  font-size: 0.67rem;
  font-weight: 600;
  letter-spacing: 0.27em;
  white-space: nowrap;
}

.brand-die {
  position: relative;
  width: 19px;
  aspect-ratio: 1;
  transform: rotate(12deg);
  border: 1px solid rgba(255, 255, 255, 0.72);
}

.brand-die i {
  position: absolute;
  width: 2px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--ink);
}

.brand-die i:nth-child(1) { top: 4px; left: 4px; }
.brand-die i:nth-child(2) { top: 8px; left: 8px; }
.brand-die i:nth-child(3) { right: 4px; bottom: 4px; }

.header-nav {
  display: flex;
  justify-content: center;
  gap: clamp(1.5rem, 4vw, 4rem);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
}

.header-nav a,
.footer-links a,
.footer-links button {
  position: relative;
  color: #adada7;
  transition: color 0.3s ease;
}

.header-nav a::after,
.footer-links a::after,
.footer-links button::after {
  position: absolute;
  right: 0;
  bottom: -0.4rem;
  left: 0;
  height: 1px;
  transform: scaleX(0);
  transform-origin: right;
  content: "";
  background: var(--accent);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.header-nav a:hover,
.header-nav a:focus-visible,
.footer-links a:hover,
.footer-links button:hover {
  color: var(--ink);
}

.header-nav a:hover::after,
.header-nav a:focus-visible::after,
.footer-links a:hover::after,
.footer-links button:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  min-height: 48px;
  padding: 0.9rem 1.4rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease, transform 0.2s ease, border-color 0.3s ease;
}

.button:hover,
.button:focus-visible {
  border-color: var(--accent);
  background: var(--accent);
  color: #050505;
}

.button:active {
  transform: scale(0.97);
}

.button:active {
  transform: scale(0.98);
}

.button-compact {
  min-height: 40px;
  padding: 0.65rem 1.15rem;
}

.button-large {
  min-height: 62px;
  padding: 1.1rem 1.8rem;
  background: var(--ink);
  color: #050505;
}

.button-light {
  border-color: var(--ink);
  background: var(--ink);
  color: #050505;
}

.button-ghost {
  background: #0b0b0b;
}

.menu-toggle,
.mobile-menu {
  display: none;
}

.page-index {
  position: fixed;
  z-index: 25;
  top: 50%;
  left: var(--page-x);
  width: calc(var(--sidebar-w) - 2.25rem);
  transform: translateY(-45%);
}

.page-index > p,
.index-key,
.chapter-label,
.project div > span,
.build-block > span,
.contact-aside span,
.system-column > span,
.heatmap-meta,
.heatmap-legend {
  margin: 0;
  color: var(--muted);
  font-size: 0.61rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.page-index > p {
  margin-bottom: 1.3rem;
}

.page-index ol {
  display: grid;
  gap: 0.42rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.page-index a {
  display: grid;
  grid-template-columns: 1.6rem 1fr;
  align-items: center;
  gap: 0.5rem;
  min-height: 23px;
  color: var(--dim);
  font-size: 0.68rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.page-index a span {
  color: #555550;
  font-size: 0.52rem;
  transition: color 0.3s ease;
}

.page-index a b {
  font-weight: 500;
}

.page-index a:hover,
.page-index a:focus-visible,
.page-index a.active {
  transform: translateX(0.3rem);
  color: var(--ink);
}

.page-index a.active span {
  color: var(--accent);
}

.index-key {
  display: flex;
  gap: 0.8rem;
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line-soft);
  letter-spacing: 0.08em;
  text-transform: none;
}

.index-key span:first-child {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.sound-toggle {
  position: fixed;
  z-index: 42;
  right: var(--page-x);
  bottom: 1.7rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: #52524f;
  font-family: var(--sans);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 220ms cubic-bezier(0.23, 1, 0.32, 1), transform 180ms cubic-bezier(0.23, 1, 0.32, 1);
}

.sound-toggle:active {
  transform: scale(0.97);
}

.sound-toggle.playing,
.sound-toggle:focus-visible {
  color: var(--ink);
}

@media (hover: hover) {
  .sound-toggle:hover { color: var(--ink); }
}

.sound-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  width: 12px;
  height: 12px;
}

.sound-bars i {
  width: 2px;
  height: 10px;
  background: currentColor;
  transform: scaleY(0.25);
  transform-origin: center;
  transition: transform 240ms cubic-bezier(0.23, 1, 0.32, 1);
}

.sound-toggle.playing .sound-bars i {
  animation: sound-level 1.4s ease-in-out infinite alternate;
}

.sound-toggle.playing .sound-bars i:nth-child(2) { animation-delay: -0.7s; }
.sound-toggle.playing .sound-bars i:nth-child(3) { animation-delay: -0.3s; }

@keyframes sound-level {
  0% { transform: scaleY(0.28); }
  100% { transform: scaleY(1); }
}

main,
.site-footer {
  margin-left: calc(var(--sidebar-w) + var(--page-x));
  border-left: 1px solid var(--line-soft);
}

.chapter {
  scroll-margin-top: var(--header-h);
}

.hero {
  /* The text and WebGL stage are composed together inside the first viewport. */
  position: relative;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(380px, 0.92fr) minmax(420px, 1.2fr);
  align-items: center;
  overflow: hidden;
  padding: calc(var(--header-h) + 2rem) var(--page-x) 3.75rem;
}

.hero::before {
  position: absolute;
  top: var(--header-h);
  right: 0;
  bottom: 0;
  left: 55%;
  border-left: 1px solid var(--line-soft);
  content: "";
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 3;
  align-self: center;
  padding-right: 1.5rem;
}

.chapter-label {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.chapter-label span:first-child {
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.hero h1 {
  margin: 1rem 0 0.3rem;
  font-family: var(--serif);
  font-size: clamp(5.4rem, 9.2vw, 10.2rem);
  font-weight: 500;
  letter-spacing: -0.075em;
  line-height: 0.66;
}

.hero h1 em {
  padding: 0 0.05em 0.04em 0;
  color: var(--accent);
  font-weight: 500;
  line-height: 1.1;
}

.hero-tagline {
  min-height: 2.9rem;
  margin: 2.6rem 0 0;
  font-family: var(--serif);
  font-size: clamp(1.55rem, 2.4vw, 2.35rem);
  line-height: 1.05;
}

.stagger-letter {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.28em);
  animation: letter-in 0.95s cubic-bezier(0.23, 1, 0.32, 1) forwards;
  animation-delay: calc(0.5s + var(--letter-index) * 25ms);
}

.stagger-word {
  display: inline-block;
  white-space: nowrap;
}

@keyframes letter-in {
  to { opacity: 1; transform: translateY(0) rotate(0); }
}

.hero-description {
  max-width: 34rem;
  margin: 1rem 0 0;
  color: #a7a7a1;
  font-size: clamp(0.92rem, 1.2vw, 1.08rem);
}

.dice-stage {
  position: absolute;
  z-index: 2;
  top: var(--header-h);
  right: 0;
  bottom: 0;
  left: 47%;
  min-width: 0;
  cursor: grab;
}

.dice-stage:active {
  cursor: grabbing;
}

#dice-canvas {
  width: 100%;
  height: 100%;
}

.dice-fallback {
  position: absolute;
  inset: 15% 12%;
  display: none;
  place-items: center;
  font-family: var(--serif);
  font-size: 3rem;
}

.dice-fallback span {
  position: absolute;
  display: grid;
  width: 10rem;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--surface-2);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.16);
}

.dice-fallback span:nth-child(1) { transform: translate(-4rem, 2rem) rotate(-12deg); }
.dice-fallback span:nth-child(2) { transform: translate(6rem, -3rem) rotate(18deg); background: var(--accent); color: #050505; }
.dice-fallback span:nth-child(3) { transform: translate(8rem, 8rem) rotate(-4deg); }

.dice-stage.no-webgl .dice-fallback {
  display: grid;
}

.dice-instruction {
  position: absolute;
  right: var(--page-x);
  bottom: 1.7rem;
  display: flex;
  gap: 0.65rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.59rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  pointer-events: none;
}

.dice-instruction b {
  color: var(--accent);
}

.scroll-indicator {
  position: absolute;
  z-index: 5;
  bottom: 1.7rem;
  left: var(--page-x);
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--muted);
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.scroll-indicator i {
  position: relative;
  width: 2.5rem;
  height: 1px;
  overflow: hidden;
  background: var(--line);
}

.scroll-indicator i::after {
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: var(--accent);
  content: "";
  animation: scroll-line 2s ease-in-out infinite;
}

@keyframes scroll-line {
  50%, 100% { transform: translateX(100%); }
}

.section {
  position: relative;
  min-height: 88dvh;
  padding: clamp(7rem, 12vw, 11rem) var(--page-x);
  border-top: 1px solid var(--line-soft);
}

.section-heading {
  max-width: 56rem;
}

.section-heading h2,
.studio-copy h2,
.faq-title h2,
.system-intro h2,
.contact-copy h2,
.build-manifesto h2 {
  max-width: 11ch;
  margin: 1.2rem 0 1rem;
  font-family: var(--serif);
  font-size: clamp(3.5rem, 7vw, 7.7rem);
  font-weight: 500;
  letter-spacing: -0.06em;
  line-height: 0.86;
}

.section-heading > p:last-child,
.system-intro > p:last-child,
.contact-copy > p:last-of-type {
  max-width: 36rem;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
}

.numbers-section {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(520px, 1.2fr);
  gap: clamp(4rem, 9vw, 9rem);
  align-items: center;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  margin: 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.stat {
  min-height: 235px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.3rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.012);
}

.stat dt {
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.stat dd {
  display: grid;
  gap: 0.5rem;
  margin: 0;
}

.stat strong {
  font-family: var(--serif);
  font-size: clamp(4.2rem, 6vw, 7.5rem);
  font-weight: 500;
  letter-spacing: -0.08em;
  line-height: 0.75;
}

.stat dd span {
  max-width: 15rem;
  color: var(--muted);
  font-size: 0.76rem;
}

.stat-wide {
  grid-row: span 2;
  min-height: 470px;
}

.stat-accent {
  background: var(--accent);
  color: #050505;
}

.stat-accent dt,
.stat-accent dd span {
  color: #303814;
}

.services-section .section-heading {
  margin-bottom: clamp(4rem, 8vw, 7rem);
}

.service-list {
  max-width: 86rem;
  margin-left: auto;
}

.service-row {
  display: grid;
  grid-template-columns: 3rem minmax(260px, 0.85fr) minmax(300px, 1fr) 2rem;
  align-items: center;
  gap: 1.75rem;
  min-height: 150px;
  border-top: 1px solid var(--line);
  transition: background-color 0.4s ease;
}

.service-row:last-child {
  border-bottom: 1px solid var(--line);
}

.service-row:hover {
  background: rgba(255, 255, 255, 0.025);
}

.service-row > span {
  color: var(--accent);
  font-size: 0.6rem;
}

.service-row h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.1rem, 3.6vw, 4.2rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.95;
}

.service-row p {
  max-width: 30rem;
  margin: 0;
  color: var(--muted);
}

.service-row i {
  font-style: normal;
  transition: transform 0.3s ease, color 0.3s ease;
}

.service-row:hover i {
  transform: translate(0.2rem, -0.2rem);
  color: var(--accent);
}

.implementation-section {
  overflow: hidden;
  background: linear-gradient(135deg, rgba(200, 255, 61, 0.025), transparent 40%);
}

.build-manifesto h2 {
  max-width: 12ch;
}

.build-stack {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: clamp(4rem, 8vw, 8rem);
  border: 1px solid var(--line);
}

.build-block {
  position: relative;
  min-height: 350px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  border-right: 1px solid var(--line);
  background: rgba(5, 5, 5, 0.4);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), background 0.3s ease;
}

.build-block:last-child {
  border-right: 0;
}

.build-block::before {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  width: 0.65rem;
  aspect-ratio: 1;
  border: 1px solid var(--accent);
  content: "";
}

.build-block:hover {
  transform: translateY(-0.75rem);
  background: #0d0d0d;
}

.build-block h3 {
  margin: 0.75rem 0 0.45rem;
  font-family: var(--serif);
  font-size: clamp(1.8rem, 2.6vw, 3.1rem);
  font-weight: 500;
  line-height: 0.95;
}

.build-block p {
  max-width: 18rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.work-section {
  padding-right: 0;
}

.work-section .section-heading {
  margin-bottom: clamp(4rem, 7vw, 7rem);
  padding-right: var(--page-x);
}

.work-grid {
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 1px;
  background: var(--line);
}

.project {
  display: grid;
  background: var(--bg);
  overflow: hidden;
}

.project-featured {
  grid-row: span 2;
}

.project figure {
  position: relative;
  min-height: 260px;
  margin: 0;
  overflow: hidden;
  background: var(--surface);
}

.project-featured figure {
  min-height: clamp(470px, 55vw, 780px);
}

.project img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.78) contrast(1.06);
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.project::after {
  position: absolute;
  content: "";
}

.project:hover img,
.project:focus-visible img {
  transform: scale(1.035);
  filter: saturate(1) contrast(1.02);
}

.project > div {
  position: relative;
  min-height: 185px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.35rem 4.25rem 1.35rem 1.35rem;
}

.project h3 {
  margin: 0.35rem 0 0.2rem;
  font-family: var(--serif);
  font-size: clamp(2rem, 3.3vw, 4rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 0.95;
}

.project:not(.project-featured) h3 {
  font-size: clamp(1.8rem, 2.5vw, 2.9rem);
}

.project p {
  max-width: 28rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
}

.project div > i {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  font-style: normal;
  transition: color 0.3s ease, transform 0.3s ease;
}

.project:hover div > i,
.project:focus-visible div > i {
  transform: translate(0.25rem, -0.25rem);
  color: var(--accent);
}

.studio-section {
  display: grid;
  grid-template-columns: minmax(360px, 0.9fr) minmax(420px, 1.1fr);
  gap: clamp(4rem, 8vw, 9rem);
  align-items: center;
}

.studio-copy h2 {
  max-width: 10ch;
}

.studio-copy > p:not(.chapter-label) {
  max-width: 38rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.studio-copy > p:nth-last-child(1) {
  color: var(--ink);
}

.studio-orbit {
  position: relative;
  min-height: min(620px, 60vw);
  border: 1px solid var(--line);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200, 255, 61, 0.07), transparent 37%);
}

.studio-orbit::before,
.studio-orbit::after {
  position: absolute;
  inset: 14%;
  border: 1px solid var(--line-soft);
  border-radius: 50%;
  content: "";
}

.studio-orbit::after {
  inset: 31%;
}

.orbit-center {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  width: 22%;
  aspect-ratio: 1;
  display: grid;
  transform: translate(-50%, -50%) rotate(10deg);
  place-items: center;
  background: var(--accent);
  color: #050505;
  box-shadow: 0 1.8rem 5rem rgba(0, 0, 0, 0.6);
}

.orbit-center span {
  transform: rotate(-10deg);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.orbit-node {
  position: absolute;
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: #c0c0ba;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.node-a { top: 11%; left: 43%; }
.node-b { top: 46%; right: 2%; }
.node-c { right: 21%; bottom: 6%; }
.node-d { bottom: 22%; left: 3%; }

.process-section {
  display: grid;
  grid-template-columns: minmax(300px, 0.72fr) minmax(520px, 1.28fr);
  gap: clamp(4rem, 9vw, 10rem);
}

.timeline {
  display: grid;
  align-self: end;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: process;
}

.timeline li {
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 1.5rem;
  min-height: 155px;
  padding: 1.75rem 0;
  border-top: 1px solid var(--line);
}

.timeline li:last-child {
  border-bottom: 1px solid var(--line);
}

.timeline > li > span {
  color: var(--accent);
  font-size: 0.63rem;
}

.timeline h3 {
  margin: 0 0 0.4rem;
  font-family: var(--serif);
  font-size: clamp(1.9rem, 3vw, 3.3rem);
  font-weight: 500;
  line-height: 1;
}

.timeline p {
  max-width: 29rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.faq-section {
  display: grid;
  grid-template-columns: minmax(300px, 0.75fr) minmax(520px, 1.25fr);
  gap: clamp(4rem, 9vw, 10rem);
}

.faq-title h2 {
  position: sticky;
  top: calc(var(--header-h) + 3rem);
}

.accordion {
  align-self: center;
}

.accordion-item {
  border-top: 1px solid var(--line);
}

.accordion-item:last-child {
  border-bottom: 1px solid var(--line);
}

.accordion-item h3 {
  margin: 0;
}

.accordion-item button {
  width: 100%;
  min-height: 106px;
  display: grid;
  grid-template-columns: 1fr 1.25rem;
  align-items: center;
  gap: 1.5rem;
  padding: 1.2rem 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.accordion-item button span {
  font-family: var(--serif);
  font-size: clamp(1.55rem, 2.5vw, 2.8rem);
  font-weight: 500;
  line-height: 1.05;
}

.accordion-item button i,
.accordion-item button i::after {
  display: block;
  width: 1rem;
  height: 1px;
  background: var(--muted);
  content: "";
  transition: transform 0.35s ease, background 0.3s ease;
}

.accordion-item button i::after {
  transform: rotate(90deg);
}

.accordion-item.open button i {
  background: var(--accent);
}

.accordion-item.open button i::after {
  transform: rotate(0);
  background: var(--accent);
}

.accordion-panel {
  overflow: hidden;
}

.accordion-panel p {
  max-width: 42rem;
  margin: 0;
  padding: 0 3.5rem 2.25rem 0;
  color: var(--muted);
}

.system-section {
  display: grid;
  align-content: center;
  background:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 7.5rem 7.5rem;
}

.system-intro {
  max-width: 62rem;
}

.system-intro h2 {
  max-width: 10ch;
}

.system-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1.35fr;
  align-items: stretch;
  gap: 1rem;
  margin-top: clamp(4rem, 7vw, 7rem);
}

.system-column,
.system-result {
  min-height: 270px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.35rem;
  border: 1px solid var(--line);
  background: rgba(5, 5, 5, 0.92);
}

.system-column h3,
.system-result h3 {
  margin: 0.6rem 0 0.3rem;
  font-family: var(--serif);
  font-size: clamp(1.7rem, 2.6vw, 2.9rem);
  font-weight: 500;
  line-height: 1;
}

.system-column p,
.system-result p {
  margin: 0;
  color: var(--muted);
  font-size: 0.76rem;
}

.system-operator {
  display: grid;
  place-items: center;
  color: var(--accent);
  font-family: var(--serif);
  font-size: 2.5rem;
}

.system-result {
  background: var(--accent);
  color: #050505;
}

.system-result p {
  color: #354016;
}

.mini-die {
  position: relative;
  width: 68px;
  aspect-ratio: 1;
  margin-bottom: auto;
  transform: rotate(10deg);
  border: 1px solid rgba(5, 5, 5, 0.6);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.45);
}

.mini-die i {
  position: absolute;
  width: 7px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #050505;
}

.mini-die i:nth-child(1) { top: 12px; left: 12px; }
.mini-die i:nth-child(2) { top: 12px; right: 12px; }
.mini-die i:nth-child(3) { top: 30px; left: 30px; }
.mini-die i:nth-child(4) { right: 12px; bottom: 12px; }
.mini-die i:nth-child(5) { bottom: 12px; left: 12px; }

.activity-section {
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  align-items: center;
  gap: clamp(4rem, 8vw, 8rem);
}

.heatmap-wrap {
  min-width: 0;
  padding: 1.4rem;
  border: 1px solid var(--line);
  background: var(--surface);
}

.heatmap-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1.4rem;
}

.heatmap-meta strong {
  color: var(--ink);
}

.heatmap {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(7, minmax(5px, 1fr));
  grid-auto-columns: minmax(5px, 1fr);
  gap: clamp(2px, 0.35vw, 5px);
  aspect-ratio: 7.6 / 1;
}

.heatmap i,
.heatmap-legend i {
  display: block;
  border: 1px solid rgba(255, 255, 255, 0.035);
  background: #161616;
}

.heatmap i[data-level="1"], .heatmap-legend i[data-level="1"] { background: #394916; }
.heatmap i[data-level="2"], .heatmap-legend i[data-level="2"] { background: #789f25; }
.heatmap i[data-level="3"], .heatmap-legend i[data-level="3"] { background: var(--accent); }

.heatmap-legend {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.42rem;
  margin-top: 1.2rem;
  letter-spacing: 0.08em;
  text-transform: none;
}

.heatmap-legend i {
  width: 9px;
  aspect-ratio: 1;
}

.contact-section {
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(420px, 1.2fr) minmax(330px, 0.8fr);
  align-items: center;
  gap: clamp(5rem, 12vw, 13rem);
  background: radial-gradient(circle at 20% 52%, rgba(200, 255, 61, 0.08), transparent 32rem);
}

.contact-copy h2 {
  max-width: 8ch;
  font-size: clamp(5rem, 9.5vw, 11rem);
}

.contact-copy .button {
  margin-top: 2.25rem;
}

.contact-aside {
  display: grid;
  align-self: center;
  border-top: 1px solid var(--line);
}

.contact-aside > div {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 1.25rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
}

.contact-aside a,
.contact-aside p {
  margin: 0;
  font-size: 0.78rem;
  overflow-wrap: anywhere;
}

.contact-aside a:hover {
  color: var(--accent);
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr 1.2fr auto auto;
  align-items: center;
  gap: 2.5rem;
  padding: 2rem var(--page-x) 5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.68rem;
}

.footer-brand {
  color: var(--ink);
  font-weight: 600;
  letter-spacing: 0.22em;
}

.site-footer p {
  margin: 0;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.cookie-consent {
  position: fixed;
  z-index: 60;
  right: clamp(1rem, 6vw, 7rem);
  bottom: clamp(1rem, 4vw, 4rem);
  left: calc(var(--sidebar-w) + var(--page-x) + clamp(0rem, 5vw, 5rem));
  grid-template-columns: minmax(320px, 1fr) auto;
  gap: 2rem;
  align-items: end;
  max-width: 900px;
  padding: 1.75rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(8, 8, 8, 0.95);
  box-shadow: 0 2rem 8rem rgba(0, 0, 0, 0.7), inset 0 1px rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(24px);
}

.cookie-consent:not([hidden]) {
  display: grid;
  animation: cookie-in 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes cookie-in {
  from { opacity: 0; transform: translateY(2rem); }
}

.cookie-copy > p:nth-child(2) {
  max-width: 38rem;
  margin: 0.7rem 0 0.35rem;
  color: #c1c1bb;
  font-size: 0.82rem;
}

.cookie-copy small {
  color: var(--muted);
}

.cookie-actions {
  display: flex;
  gap: 0.75rem;
}

.cookie-close {
  position: absolute;
  top: 0.8rem;
  right: 0.9rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 1.2rem;
  cursor: pointer;
}

.reveal {
  /* IntersectionObserver adds .visible once, avoiding per-frame scroll work. */
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.95s cubic-bezier(0.23, 1, 0.32, 1), transform 0.95s cubic-bezier(0.23, 1, 0.32, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 5px;
}

@media (max-width: 1180px) {
  :root {
    --sidebar-w: 178px;
    --page-x: clamp(1.25rem, 3vw, 2.5rem);
  }

  .site-header {
    grid-template-columns: var(--sidebar-w) 1fr auto;
  }

  .hero {
    grid-template-columns: minmax(330px, 0.9fr) minmax(380px, 1.1fr);
  }

  .hero h1 {
    font-size: clamp(5.2rem, 9.7vw, 8rem);
  }

  .service-row {
    grid-template-columns: 2rem minmax(250px, 0.85fr) minmax(260px, 1fr) 1.5rem;
  }

  .build-stack {
    grid-template-columns: repeat(2, 1fr);
  }

  .build-block:nth-child(2) {
    border-right: 0;
  }

  .build-block:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .studio-orbit {
    min-height: 480px;
  }
}

@media (max-width: 920px) {
  /* High-variance desktop layouts collapse into clear single-column stories. */
  :root {
    --header-h: 64px;
  }

  .site-header {
    grid-template-columns: 1fr auto;
  }

  .header-nav,
  .header-cta,
  .page-index {
    display: none;
  }

  .menu-toggle {
    width: 42px;
    height: 42px;
    display: grid;
    align-content: center;
    gap: 6px;
    padding: 0 9px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
  }

  .menu-toggle span:not(.sr-only) {
    display: block;
    width: 100%;
    height: 1px;
    background: var(--ink);
    transition: transform 0.3s ease;
  }

  .menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }

  .mobile-menu {
    position: fixed;
    z-index: 38;
    top: var(--header-h);
    right: 0;
    left: 0;
    display: grid;
    visibility: hidden;
    padding: 1.5rem var(--page-x) 2rem;
    transform: translateY(-1rem);
    border-bottom: 1px solid var(--line);
    background: rgba(5, 5, 5, 0.98);
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  }

  .mobile-menu.open {
    visibility: visible;
    transform: translateY(0);
    opacity: 1;
  }

  .mobile-menu a {
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--line-soft);
    font-family: var(--serif);
    font-size: 1.8rem;
  }

  main,
  .site-footer {
    margin-left: 0;
    border-left: 0;
  }

  .hero {
    grid-template-columns: 1fr;
    align-content: start;
    padding-top: calc(var(--header-h) + 3.5rem);
  }

  .hero::before {
    display: none;
  }

  .hero-copy {
    align-self: start;
  }

  .hero h1 {
    font-size: clamp(5.4rem, 17vw, 9.5rem);
  }

  .hero-tagline {
    margin-top: 2rem;
  }

  .dice-stage {
    top: 30%;
    left: 30%;
    opacity: 0.78;
  }

  .numbers-section,
  .studio-section,
  .process-section,
  .faq-section,
  .activity-section,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .numbers-section {
    gap: 4rem;
  }

  .stats-grid {
    max-width: 700px;
  }

  .service-row {
    grid-template-columns: 2rem 1fr 2rem;
  }

  .service-row p {
    grid-column: 2 / 3;
  }

  .service-row i {
    grid-column: 3;
    grid-row: 1;
  }

  .work-section {
    padding-right: var(--page-x);
  }

  .work-grid {
    grid-template-columns: 1fr;
  }

  .project-featured {
    grid-row: auto;
  }

  .project figure,
  .project-featured figure {
    min-height: min(62vw, 560px);
  }

  .studio-orbit {
    width: min(100%, 620px);
    min-height: auto;
    aspect-ratio: 1;
    margin: 0 auto;
  }

  .process-section,
  .faq-section {
    gap: 4rem;
  }

  .faq-title h2 {
    position: static;
  }

  .system-diagram {
    grid-template-columns: 1fr auto 1fr;
  }

  .system-result {
    grid-column: 1 / -1;
  }

  .system-diagram .system-operator:nth-of-type(2) {
    display: none;
  }

  .contact-section {
    gap: 5rem;
  }

  .site-footer {
    grid-template-columns: 1fr 1fr;
  }

  .cookie-consent {
    left: clamp(1rem, 6vw, 7rem);
  }
}

@media (max-width: 640px) {
  :root {
    --page-x: 1.2rem;
  }

  body {
    font-size: 14px;
  }

  .brand span:last-child {
    font-size: 0.6rem;
  }

  .sound-toggle {
    right: 1.2rem;
    bottom: 1rem;
    padding: 0.45rem 0.6rem;
    background: rgba(5, 5, 5, 0.86);
    backdrop-filter: blur(8px);
  }

  .hero {
    min-height: 100svh;
    padding-top: calc(var(--header-h) + 2.8rem);
  }

  .hero h1 {
    font-size: clamp(4.8rem, 25vw, 7rem);
    line-height: 0.7;
  }

  .hero-tagline {
    max-width: 70%;
    font-size: 1.45rem;
  }

  .hero-description {
    max-width: 70%;
    font-size: 0.82rem;
  }

  .dice-stage {
    top: 43%;
    left: 18%;
    transform: translateX(19%);
    opacity: 0.64;
  }

  .dice-instruction {
    right: 1.2rem;
    bottom: 4rem;
  }

  .scroll-indicator {
    bottom: 1.2rem;
  }

  .section {
    min-height: auto;
    padding-top: 7rem;
    padding-bottom: 7rem;
  }

  .section-heading h2,
  .studio-copy h2,
  .faq-title h2,
  .system-intro h2,
  .build-manifesto h2 {
    font-size: clamp(3.3rem, 17vw, 5rem);
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .stat,
  .stat-wide {
    grid-row: auto;
    min-height: 220px;
  }

  .service-row {
    grid-template-columns: 1.5rem 1fr 1rem;
    gap: 0.75rem;
    padding: 1.5rem 0;
  }

  .service-row:hover {
    padding-right: 0;
    padding-left: 0;
  }

  .service-row h3 {
    font-size: 2.2rem;
  }

  .build-stack {
    grid-template-columns: 1fr;
  }

  .build-block {
    min-height: 280px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .build-block:last-child {
    border-bottom: 0;
  }

  .project figure,
  .project-featured figure {
    min-height: 76vw;
  }

  .project > div {
    min-height: 165px;
  }

  .studio-orbit {
    width: calc(100vw - 2.4rem);
  }

  .orbit-node {
    font-size: 0.52rem;
  }

  .timeline li {
    grid-template-columns: 2rem 1fr;
  }

  .accordion-item button {
    min-height: 92px;
  }

  .system-section {
    background-size: 4.5rem 4.5rem;
  }

  .system-diagram {
    grid-template-columns: 1fr;
  }

  .system-operator {
    min-height: 2.5rem;
  }

  .system-result {
    grid-column: auto;
  }

  .system-diagram .system-operator:nth-of-type(2) {
    display: grid;
  }

  .heatmap-wrap {
    padding: 1rem;
    overflow-x: auto;
  }

  .heatmap {
    min-width: 660px;
  }

  .contact-section {
    min-height: 100svh;
  }

  .contact-copy h2 {
    font-size: clamp(5rem, 25vw, 8rem);
  }

  .contact-aside > div {
    grid-template-columns: 6rem 1fr;
  }

  .site-footer {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding-bottom: 5rem;
  }

  .footer-links {
    flex-wrap: wrap;
  }

  .cookie-consent {
    right: 0.75rem;
    bottom: 0.75rem;
    left: 0.75rem;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    padding: 1.25rem;
  }

  .cookie-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  /* Every perpetual and entrance animation resolves to a static state. */
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .reveal,
  .stagger-letter {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .site-header,
  .sound-toggle,
  .cookie-consent {
    background: #080808;
    backdrop-filter: none;
  }
}
