@font-face {
  font-family: "Instrument Sans";
  src: url("assets/fonts/InstrumentSans-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Sans";
  src: url("assets/fonts/InstrumentSans-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Sans";
  src: url("assets/fonts/InstrumentSans-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Sans";
  src: url("assets/fonts/InstrumentSans-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src: url("assets/fonts/IBMPlexMono-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #faf6f0;
  --rest: #f0eae1;
  --ink: #262a33;
  --sage: #5e6a61;
  --deep-blue: #152e63;
  --deep-orange: #a8380a;
  --focus-blue: #1740d8;
  --signal-orange: #ff7a00;
  --line: rgba(38, 42, 51, 0.22);
  --header-height: 80px;
  --mobile-stage-height: clamp(238px, 31svh, 294px);
  --gutter: clamp(18px, 3vw, 48px);
  color-scheme: light;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-width: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Instrument Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

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

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

.skip-link {
  position: fixed;
  z-index: 100;
  top: 10px;
  left: 10px;
  padding: 10px 14px;
  background: var(--paper);
  color: var(--ink);
  border: 2px solid var(--focus-blue);
  transform: translateY(-160%);
}

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

.site-header {
  position: sticky;
  z-index: 30;
  top: 0;
  display: grid;
  grid-template-columns: minmax(260px, 290px) 1fr auto;
  align-items: center;
  min-height: var(--header-height);
  padding: 10px var(--gutter);
  border-bottom: 1px solid var(--ink);
  background: var(--paper);
}

.brand {
  display: inline-flex;
  align-items: center;
  width: min(270px, 100%);
}

.brand img {
  display: block;
  width: 100%;
  height: auto;
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: clamp(16px, 2.4vw, 34px);
}

.site-nav a {
  position: relative;
  padding: 12px 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: 7px;
  left: 0;
  height: 2px;
  background: var(--focus-blue);
  content: "";
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 120ms ease;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after,
.site-nav a[aria-current="true"]::after {
  transform: scaleX(1);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 0;
  font: 500 15px/1 "Instrument Sans", sans-serif;
  text-align: center;
  text-decoration: none;
  transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
}

.button-primary {
  background: var(--deep-blue);
  color: var(--paper);
}

.button-primary:hover {
  background: var(--deep-orange);
}

.button:disabled {
  background: var(--sage);
  cursor: not-allowed;
  opacity: 0.72;
}

.button-secondary {
  border-color: var(--ink);
  background: var(--paper);
  color: var(--ink);
}

.button-secondary:hover {
  background: var(--ink);
  color: var(--paper);
}

.eyebrow {
  margin: 0;
  color: var(--deep-blue);
  font: 500 10px/1.5 "IBM Plex Mono", ui-monospace, monospace;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.045em;
  text-wrap: balance;
}

h1 {
  max-width: 12ch;
  font-size: clamp(44px, 5.2vw, 76px);
  line-height: 0.96;
}

h2 {
  max-width: 14ch;
  font-size: clamp(39px, 4.3vw, 62px);
  line-height: 0.99;
}

.lead {
  margin: 0;
  color: rgba(38, 42, 51, 0.84);
  font-size: clamp(16px, 1.35vw, 19px);
  line-height: 1.55;
  text-wrap: pretty;
}

.microcopy {
  margin: 0;
  color: rgba(38, 42, 51, 0.66);
  font-size: 13px;
  line-height: 1.5;
}

.text-link {
  width: fit-content;
  padding: 8px 0 5px;
  border-bottom: 2px solid var(--deep-orange);
  color: var(--deep-orange);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

.text-link:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.desktop-experience {
  display: none;
}

.mobile-experience {
  position: relative;
  display: block;
  background: var(--paper);
}

.mobile-scene-stage {
  position: sticky;
  z-index: 20;
  top: var(--header-height);
  height: var(--mobile-stage-height);
  overflow: hidden;
  overflow: clip;
  border-bottom: 1px solid var(--ink);
  background: #1b1c1e;
  isolation: isolate;
}

.mobile-scene-plane {
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  --focus-x: 6.5%;
  --focus-y: 45%;
  --focus-rx: 10.5%;
  --focus-ry: 24%;
  transform: translate3d(-50%, -50%, 0) scale(1.55);
  will-change: transform;
}

.mobile-scene-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: fill;
  filter: blur(5px);
}

.mobile-scene-focus {
  position: absolute;
  inset: 0;
  background: url("../site-build-unpacked/assets/clickwork-studio-master-1280.webp?v=4") center / 100% 100% no-repeat;
  -webkit-mask-image: radial-gradient(
    ellipse var(--focus-rx) var(--focus-ry) at var(--focus-x) var(--focus-y),
    #000 0%,
    #000 48%,
    rgba(0, 0, 0, 0.88) 62%,
    transparent 100%
  );
  mask-image: radial-gradient(
    ellipse var(--focus-rx) var(--focus-ry) at var(--focus-x) var(--focus-y),
    #000 0%,
    #000 48%,
    rgba(0, 0, 0, 0.88) 62%,
    transparent 100%
  );
  pointer-events: none;
}

.mobile-scene-caption {
  position: absolute;
  z-index: 2;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: max-content 1fr;
  align-items: center;
  gap: 18px;
  min-height: 38px;
  padding: 0 24px;
  border-top: 1px solid rgba(250, 246, 240, 0.5);
  background: rgba(250, 246, 240, 0.9);
  backdrop-filter: blur(12px);
}

.mobile-scene-label {
  color: var(--ink);
  font: 500 9px/1 "IBM Plex Mono", ui-monospace, monospace;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.mobile-scene-rule {
  position: relative;
  display: block;
  height: 1px;
  overflow: visible;
  background: rgba(38, 42, 51, 0.25);
}

.mobile-scene-progress {
  position: absolute;
  top: -1px;
  right: 0;
  bottom: -1px;
  left: 0;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  will-change: transform;
}

.mobile-story {
  position: relative;
  z-index: 1;
}

.mobile-chapter {
  display: flex;
  min-height: max(64svh, 470px);
  scroll-margin-top: calc(var(--header-height) + var(--mobile-stage-height));
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.mobile-content {
  display: grid;
  align-content: start;
  gap: 18px;
  width: min(100%, 44rem);
  margin: 0 auto;
  padding: clamp(38px, 7svh, 72px) 24px clamp(54px, 9svh, 92px);
}

.mobile-content h1 {
  max-width: 14ch;
  font-size: clamp(40px, 10.2vw, 56px);
}

.mobile-content h2 {
  max-width: 15ch;
  font-size: clamp(34px, 8.8vw, 48px);
}

.project-list {
  display: grid;
  margin: 4px 0 0;
  padding: 0;
  border-top: 2px solid var(--ink);
  list-style: none;
}

.project-list li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.project-list strong {
  font-size: 15px;
  font-weight: 600;
}

.project-list span {
  color: var(--sage);
  font: 400 9px/1.4 "IBM Plex Mono", ui-monospace, monospace;
  letter-spacing: 0.09em;
  text-align: right;
  text-transform: uppercase;
}

.studio-credit {
  display: grid;
  gap: 5px;
  margin-top: 4px;
  padding: 14px 0 0;
  border-top: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

.studio-credit span {
  color: var(--sage);
  font: 500 9px/1.4 "IBM Plex Mono", ui-monospace, monospace;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.studio-credit small {
  font-size: 12px;
  line-height: 1.45;
}

@media (min-width: 761px) and (max-width: 1100px) {
  .site-nav {
    display: none;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 66px;
  }

  .site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding-right: 16px;
    padding-left: 16px;
  }

  .brand {
    width: clamp(118px, 38vw, 154px);
  }

  .site-nav {
    display: none;
  }

  .header-cta {
    min-height: 44px;
    padding: 0 10px;
    font-size: 11px;
    letter-spacing: -0.01em;
  }

  .button-row {
    display: grid;
  }

  .button-row .button {
    width: 100%;
  }
}

@media (min-width: 960px) and (prefers-reduced-motion: no-preference) {
  .is-enhanced .site-header {
    position: fixed;
    right: 0;
    left: 0;
    background: rgba(250, 246, 240, 0.96);
    backdrop-filter: blur(14px);
  }

  .is-enhanced .desktop-experience {
    position: relative;
    display: block;
    height: 600svh;
    background: var(--ink);
  }

  .is-enhanced .mobile-experience {
    display: none;
  }

  .scene-stage {
    position: sticky;
    top: 0;
    height: 100svh;
    overflow: hidden;
    overflow: clip;
    background: #1b1c1e;
    isolation: isolate;
    --rail-width: min(920px, calc(100vw - 80px));
  }

  .scene-plane {
    position: absolute;
    z-index: -4;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 100vh;
    --focus-x: 6.5%;
    --focus-y: 45%;
    --focus-rx: 10.5%;
    --focus-ry: 24%;
    will-change: transform;
  }

  .scene-plane picture,
  .scene-plane img {
    display: block;
    width: 100%;
    height: 100%;
  }

  .scene-plane img {
    object-fit: fill;
    filter: blur(6px);
  }

  .scene-focus {
    position: absolute;
    inset: 0;
    background: url("../site-build-unpacked/assets/clickwork-studio-master.webp?v=4") center / 100% 100% no-repeat;
    -webkit-mask-image: radial-gradient(
      ellipse var(--focus-rx) var(--focus-ry) at var(--focus-x) var(--focus-y),
      #000 0%,
      #000 48%,
      rgba(0, 0, 0, 0.88) 62%,
      transparent 100%
    );
    mask-image: radial-gradient(
      ellipse var(--focus-rx) var(--focus-ry) at var(--focus-x) var(--focus-y),
      #000 0%,
      #000 48%,
      rgba(0, 0, 0, 0.88) 62%,
      transparent 100%
    );
    pointer-events: none;
  }

  .desktop-copy {
    position: absolute;
    z-index: 3;
    top: clamp(104px, 13vh, 132px);
    left: var(--gutter);
    display: grid;
    gap: 18px;
    width: min(32rem, 40vw);
    max-height: calc(100svh - 220px);
    padding: clamp(22px, 2.2vw, 32px);
    overflow: visible;
    border: 1px solid rgba(250, 246, 240, 0.52);
    border-radius: 8px;
    background: rgba(250, 246, 240, 0.95);
    backdrop-filter: blur(12px) saturate(0.82);
    clip-path: inset(4px 0 0 0 round 8px);
    filter: blur(1px);
    opacity: 0;
    pointer-events: none;
    transform: translateY(3px) scale(0.995);
    transition:
      opacity 280ms ease,
      transform 340ms cubic-bezier(0.4, 0, 1, 1),
      filter 260ms ease,
      clip-path 340ms cubic-bezier(0.4, 0, 1, 1),
      visibility 0s linear 360ms;
    visibility: hidden;
    will-change: opacity, transform, filter, clip-path;
  }

  .desktop-copy::before {
    position: absolute;
    top: -1px;
    left: clamp(22px, 2.2vw, 32px);
    width: 42px;
    height: 2px;
    background: var(--deep-blue);
    content: "";
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 160ms ease;
  }

  .desktop-copy[data-side="right"] {
    right: calc((100% - var(--rail-width)) / 2);
    left: auto;
  }

  .desktop-copy[data-copy="inspireren"],
  .desktop-copy[data-copy="activeren"] {
    right: max(var(--gutter), calc((100% - var(--rail-width)) / 2 - 44px));
    left: auto;
  }

  .desktop-copy[data-copy="innoveren"],
  .desktop-copy[data-copy="projecten"],
  .desktop-copy[data-copy="contact"] {
    right: auto;
    left: calc((100% - var(--rail-width)) / 2);
  }

  .desktop-copy.is-active {
    clip-path: inset(0 round 8px);
    filter: blur(0);
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    transition:
      opacity 420ms 90ms cubic-bezier(0.16, 1, 0.3, 1),
      transform 460ms 70ms cubic-bezier(0.16, 1, 0.3, 1),
      filter 320ms 70ms ease,
      clip-path 460ms 60ms cubic-bezier(0.16, 1, 0.3, 1),
      visibility 0s;
    visibility: visible;
  }

  .desktop-copy.is-active::before {
    transform: scaleX(1);
    transition: transform 360ms 220ms cubic-bezier(0.16, 1, 0.3, 1);
  }

  .desktop-copy[data-copy="intro"] h1 {
    max-width: 14ch;
    font-size: clamp(46px, 4vw, 60px);
    line-height: 0.98;
  }

  .desktop-copy.projects-copy {
    top: clamp(98px, 13vh, 128px);
    gap: 14px;
  }

  .desktop-copy.projects-copy h2 {
    font-size: clamp(38px, 3.6vw, 52px);
  }

  .desktop-copy.contact-copy {
    gap: 14px;
  }

  .scene-status {
    position: absolute;
    z-index: 4;
    top: calc(var(--header-height) + 20px);
    right: var(--gutter);
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(250, 246, 240, 0.7);
    font: 500 10px/1 "IBM Plex Mono", ui-monospace, monospace;
    letter-spacing: 0.16em;
    text-transform: uppercase;
  }

  .chapter-nav {
    position: absolute;
    z-index: 5;
    bottom: 18px;
    left: 50%;
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    width: var(--rail-width);
    padding: 0 18px 5px;
    border-radius: 4px;
    border: 1px solid rgba(250, 246, 240, 0.58);
    background: rgba(250, 246, 240, 0.82);
    backdrop-filter: blur(14px) saturate(0.78);
    transform: translateX(-50%);
  }

  .chapter-nav::before {
    position: absolute;
    top: 9px;
    right: 24px;
    left: 24px;
    height: 1px;
    background: rgba(38, 42, 51, 0.36);
    content: "";
  }

  .chapter-nav button {
    position: relative;
    min-height: 42px;
    padding: 18px 10px 0;
    border: 0;
    border-right: 0;
    border-radius: 0;
    background: transparent;
    color: rgba(38, 42, 51, 0.64);
    font: 500 10px/1 "Instrument Sans", sans-serif;
    cursor: pointer;
    transition: color 180ms ease;
  }

  .chapter-nav button::before {
    position: absolute;
    z-index: 1;
    top: 9px;
    left: 50%;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(38, 42, 51, 0.5);
    content: "";
    transform: translate(-50%, -50%);
    transition:
      width 240ms cubic-bezier(0.22, 1, 0.36, 1),
      height 240ms cubic-bezier(0.22, 1, 0.36, 1),
      background-color 180ms ease;
  }

  .chapter-nav button:last-child {
    border-right: 0;
  }

  .chapter-nav button:hover,
  .chapter-nav button[aria-current="true"] {
    background: transparent;
    color: var(--ink);
  }

  .chapter-nav button:hover::before {
    width: 6px;
    height: 6px;
  }

  .chapter-nav button[aria-current="true"]::before {
    width: 8px;
    height: 8px;
    background: var(--ink);
    animation: chapter-pulse 2.2s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  }

  .scroll-track {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: grid;
    grid-template-rows: 12fr 20fr 20fr 20fr 16fr 12fr;
    pointer-events: none;
  }

  .scroll-track > div {
    scroll-margin-top: var(--header-height);
  }
}

@keyframes chapter-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(38, 42, 51, 0.3);
    transform: translate(-50%, -50%) scale(1);
  }

  55% {
    box-shadow: 0 0 0 5px rgba(38, 42, 51, 0);
    transform: translate(-50%, -50%) scale(1.12);
  }
}

@media (min-width: 960px) and (max-height: 760px) and (prefers-reduced-motion: no-preference) {
  .desktop-copy {
    top: 94px;
    gap: 12px;
    max-height: calc(100svh - 172px);
    padding: 22px 26px;
  }

  .desktop-copy h1 {
    font-size: clamp(44px, 4.5vw, 60px);
  }

  .desktop-copy h2 {
    font-size: clamp(38px, 3.8vw, 52px);
  }

  .desktop-copy .lead {
    font-size: 16px;
  }

  .chapter-nav {
    bottom: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

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

  .mobile-scene-plane,
  .mobile-scene-progress {
    will-change: auto;
  }
}
